Can't seem to change to customer weather file

3 posts / 0 new
Last post
sbarsun
Can't seem to change to customer weather file

Hi,

In the 'old' scripting langauge, we succesfully used a line like this to set the weather for a PV site to be an actual weather file:
setinput( "climate.location", "K:/IPL/Program Folders/Renewables/WeatherData/IOWA_2010-15_4_CITIES_rev1/" + filename + "/" + filename + ".epw" )

Under the new scripting language, we've tried a variety of variables to set to a custom weather file but all teh simulations seem to use the same weather we start with. Example:
if (Station=="ALGONA")
{filename = "IA_" + Station + "_725457_" + run_yr;}
elseif (Station=="DECORAH-MUNI")
{filename = "IA_" + Station + "_725476_" + run_yr;}
elseif (Station=="PERRY-MUNI-AP")
{filename = "IA_" + Station + "_720412_" + run_yr;}
elseif (Station=="WASHINGTON")
{filename = "IA_" + Station + "_725454_" + run_yr;}

outln("filename: " + filename);

set( "solar_resource_file", filename + ".epw" );

Is it obvious what we're doing wrong?

Thanks,
Stephan

sbarsun

I seem to have found it in one of the LK examples:

//set location and resource mode to 'use a specific weather file on disk'
set('use_specific_weather_file',1);

Paul Gilman

Hello,

Yes, you'll need to set use_specific_weather_file to 1, and then set user_specified_weather_file to a string whose value is the weather file's full path and name.

I added a new file to the LK Script Cookbook that demonstrates how to work with solar resource data.

Best regards,
Paul.

Theme by Danetsoft and Danang Probo Sayekti inspired by Maksimer