Home Image

Climate Modeling Alliance

API: How to Guide

Overview

CliDApp's API allows its users to download climate files without interacting with its UI.


The following cities are available for download:

  • Atlanta, GA, USA. City code: ATL.
  • Boston, MA, USA. City code: BOS.
  • Chicago, IL, USA. City code: CHI.
  • Cincinnati, OH, USA. City code: CIN.
  • Las Vegas, NV, USA. City code: LAV.
  • Los Angeles, CA, USA. City code: LAX.
  • Minneapolis, MN, USA. City code: MIN.
  • New York, NY, USA. City code: NYC.
  • Portland, OR, USA. City code: POR.
  • San Francisco, CA, USA. City code: SFO.
  • Sacramento, CA, USA. City code: SAC.


To download a meterological year file for a given station, you will need:

Field Field Name Available Options
descon-code Design Condition Code ashrae, ufc
city-code City Code See available cities above.
data-type Data Type Code obs = Observations.
period-type-code Period Type Code obs = Observations, proj = Projections
filetype-code File Type Code csv, json

  1. The design condition code. The respective design condition codes are ashrae and ufc for the ASHRAE and Unified Criteria Design Chart.
  2. The city code of the city of interest. See the available cities list above.
  3. The desired data type code. The respective codes for observation and reanalysis data types are obs and rea. Please note that currently only observation data is available.
  4. The start year and end year of the period of interest.
  5. The period type code. The respective codes for observation and projection periods are obs and proj.
  6. The file type code of interest code. The filetype codes are csv and json.

Please note that this json is not a json file but a json response.

With this, formulate the download URL.

https://ecodesign.clima.caltech.edu/server/descon-code/city-code/data-type/start-year/end-year/period-type-code/filetype-code

Example URL for ASHRAE chart download for New York, NY, USA for observations from 1994-2019.

https://ecodesign.clima.caltech.edu/server/ashrae/NYC/obs/1994/2019/obs/json


Meteorological Year Files Download Guide

To download a meterological year file for a given station, you will need:

Field Field Name Available Options
city-code City Code See available cities above.
climate-file-code Climate File Code amy, tmy, ftmy
data-type Data Type Code amy, tmy, ftmy
filetype-code File Type Code csv, epw, json

  1. The city code of the city of interest. See the available cities list above.
  2. The climate file code. The respective codes are amy, tmy and ftmy for actual meteorological year, typical meteorological year and future typical meteorological year.
  3. The desired data type code. The respective codes for observation and reanalysis data types are obs and rea. Please note that currently only observation data is available.
  4. The start year and end year of the period of interest. Please note that if the climate file is AMY, the start and end year must be equal.
  5. The file type code. The filetype codes are csv, epw and json.

With this, formulate the download URL.

https://ecodesign.clima.caltech.edu/server/city-code/climate-file-code/data-type/start-year/end-year/filetype-code

Example URL for AMY file download for New York, NY, USA for 2019.

https://ecodesign.clima.caltech.edu/server/NYC/amy/obs/2019/2019/epw


Below we provide user guides of the API in Python and Julia


The following is a Python code snippet that demonstrates how to download a design condition statistic files, meteorological year files and an example visialization of the data.

CliDApp_API_Guide_

Download the Python API Guide Jupyter Notebook below




The following is a Julia code snippet that demonstrates how to download meteorological year files and an example visialization of the data.

JuliaAPIGuide

Download the Julia API Guide Jupyter Notebook below