SAM CSV Format for Solar

SAM CSV Format for Solar#

The SAM CSV format is a comma-separated text format for SAM’s solar performance models. It uses a standard CSV format that you can edit in any spreadsheet program, text editor, or other appropriate software.

SS_SolarResource-samcsv-file.png

For examples of files in the SAM CSV format, see files in the solar_resource folder of your SAM installation folder.

The SAM CSV format supports hourly and subhourly data with up to a one-minute resolution. SAM recognizes the weather file’s time resolution based on the number of data rows in the weather file. For example, SAM recognizes a file with 8,670 data rows as an hourly data file, and a file with 35,040 rows as 15-minute data. A minute column is optional for hourly data, and required for sub-hourly data. By default, for hourly data SAM calculates sun position angles at the mid-point of the hour. However, if you specify the optional minute column for the hourly data, SAM calculates the sun position at the minute indicated in that column. For sub-hourly data, sun angles are calculated for the minute indicated in the Minute column. See Time Convention and Sun Position for additional details.

SAM requires a valid value for all time steps for each data element. It does not fill data gaps. It does perform some checks on the weather data before running a simulation, and displays messages about problems with the data in the simulation notices. You can also run the Solar Resource File Checker macro to perform the checks without running a simulation.

Solar Resource Data#

Rows 3 and higher contain solar resource data.

Row 3#

Labels identifying the data columns. SAM uses the labels to identify the columns, so they can be in any order. SAM requires a complete column of data for each data element. The Minute column is optional for hourly data.

For example, a valid Row 3 might look like this:

Year,Month,Day,Hour,Minute,GHI,DNI,DHI,Tdry,Tdew,RH,Pres,Wspd,Wdir,Snow Depth

See the table below for a complete list of valid Row 3 header values and units. See the description of the Units flag above if you want to include an additional row for units in your file.

Row 4-8,760 (for hourly data, more rows for sub-hourly data)

Data identified in Row 3. For example:

1988,1,1,0,0,0,0,5.6,-3.3,53,983,2.1,200,0

SAM assumes that the weather data uses the following units:

Note

The format does not require leading zeros in one-digit numbers.

  • Year is a four-digit integer (1988)

  • Month is a one- or two-digit integer (Month = 1 is January)

  • Day is a one- or two-digit integer indicating the day of month (Day = 1 is the first day of the month).

  • Hour is a one- or two-digit integer indicating the hour of day (Hour = 0 is the first hour of the day, or the hour ending at 1 am).

  • Minute is a one-or two-digit integer indicating the minute (Minute = 0 is the first minute of the hour). This value is required for sub-hourly data, and optional for hourly data. For hourly data, the minute column indicates the time you want SAM to use for sun position calculations. If you omit the value for hourly data, SAM uses the midpoint of the hour for the calculations. See Time Convention and Sun Position for details.

  • Solar irradiance in W/m2. SAM’s photovoltaic models assume instantaneous irradiance. The CSP models assume average irradiance over the time step.

  • Temperature in °C.

  • Relative humidity in %.

  • Atmospheric pressure in millibar.

  • Wind speed at 10 meters above the ground in m/s.

  • Wind direction at 10 meters above the ground in degrees east of North, with zero degrees indicating wind from the north.

  • Snow depth in centimeters.

Data Field

Units

Accepted Labels for Row 3

Year

1950-2050

year, yr

Month

1-12

month, mo

Day

1-31

day

Hour

0-23

hour, hr

Minute

0-59

min, minute

Global horizontal irradiance

W/m²

gh, ghi, global, global horizontal, global horizontal irradiance

Beam normal irradiance

W/m²

dn, dni, beam, direct normal, direct normal irradiance

Diffuse horizontal irradiance

W/m²

df, dhi, diffuse, diffuse horizontal, diffuse horizontal irradiance

Plane-of-array irradiance

W/m²

poa, pa, plane,plane of array,plane of array irradiance, poa_global

Ambient dry bulb temperature

°C

tdry, dry bulb, dry bulb temp, temperature, ambient, ambient temp, temp_air

Wet bulb temperature

°C

twet, wet bulb, wet bulb temperature

Dew point temperature

°C

Tdew, dew point, dew point temperature, temp_dew

Wind speed

m/s

wspd, wind speed, wind_speed

Wind direction

degrees

wdir, wind direction, wind_direction

Relative humidity

%

rh, rhum, relative humidity, humidity, relative_humidity

Atmospheric pressure

Millibar

pres, pressure

Snow depth

cm

snow, snow cover, snow depth

Ground reflectance (albedo)

0..1

albedo, alb, surface albedo

Aerosol optical depth

0..1

aod, aerosol, aerosol optical depth