Welcome to WEAP's Website WEAP
WEAP is an initiative of the Stockholm Environment Institute.


About WEAP

Home
Why WEAP?
Features
What's New?
Sample Screens
Demonstration
Publications
History and Credits

Using WEAP
Download
Licensing
User Guide
Tutorial
Videos (YouTube)

User Forum
Discussions
Members List
Edit Profile

Additional Support
Training
University Courses
Collaboration

About Us
SEI-US Water Resources Program
Please Contact Us

LEAP
Interested in Energy?
Read about LEAP: SEI's software for energy planning.

Link WEAP and LEAP for combined Water-Energy planning.
Watch a video demo!
   

User Forum

All Topics | Topic "How to arrange data in excel csv fromat"
Log in to post new messages or reply to existing messages.
 
Author Message
Mr. Naveed Ahmed

Subject: How to arrange data in excel csv fromat   
Posted: 12/11/2015 Viewed: 16942 times
Hi,
This is Naveed and I am using WEAP since last 2 years, I have run my model for demand based irrigation requirement. I have reinstalled my new windoa nd latest model of WEAP and facing a problem. I have copied my previously developed model in the new WEAP Model directory and when I run my model it gives error with following indication
some time it indicate "your first row is empty"
some time it says "first row will be a year"

and I want to ask how I may arrange my data in CSV format?
I have dd-mm-yyyy in the first colum and in the second column data required.
I have to arrange data in this format (YYYY in first column, Month in second column, date in thired column and data in fourth column) or some other format. Please let me know.
I have not made any change in the model developed in older version and new version and in the older version this model have not gave any problem and why it is indicating error now??
Is there any restriction or special format to be adop in this new version???
Mr. Jack Sieber

Subject: Re: How to arrange data in excel csv fromat   
Posted: 12/11/2015 Viewed: 16937 times
WEAP's ReadFromFile function can read CSV files either in daily format or monthly.

Daily data file start each line with the date, e.g., 1/31/2015. Monthly data files start each line with year, month, e.g., 2015, 1.

Your problem might be that WEAP does not recognize your date format. By default, WEAP will use the Windows system "Short date" format (set in the "Regional and Language Options" Windows Control Panel) for interpreting daily dates, e.g., mm/dd/yyyy or dd/mm/yyyy. However, because you may want to share your WEAP area with someone in another country (whose regional settings are different), it is best practice to include in the file a line that specifies the date format used. To do this, place a $DateFormat directive into the CSV file, on a line at the top before the data values. For example, to specify dd-mm-yyyy as the date format, include the following line at the top of the file:

$DateFormat = dd-mm-yyyy

Some other examples:

$DateFormat = mm/dd/yyyy
$DateFormat = d-m-y
$DateFormat = m d y
$DateFormat = d/m/y
$DateFormat = yyyy/m/d

See http://www.weap21.org/WebHelp/Read_From_File.htm for more information on the ReadFromFile function.

Jack
Eng. Paul Ramirez

Subject: Re: How to arrange data in excel csv fromat   
Posted: 10/18/2016 Viewed: 15611 times
Hi Jack. This is Paul, and I'm having similar problems with the CSV formats required by the WEAP. In my particular case im trying to add daily climate data to my model, but while I'm using the "readfile wizard" an error occurs whit the following indication:

Duplicate monthly data for year= XXXX, month=XXXX.

My data are organized YYYY/mm/dd, because when I tryed to use dd/mm/YYYY weap just said me, that I have to use year first. I tryed to use the $DateFormat directive as you suggest in the last message, but It didn't work to me. Could you please tell me what I'm doing wrong.
Ms. Stephanie Galaitsi

Subject: Re: How to arrange data in excel csv fromat   
Posted: 10/19/2016 Viewed: 15601 times
Dear Paul,

Are you sure you don't have duplicate dates somewhere in your spreadsheet? For instance, the year 2009 might accidentally extend into January 2010, and then you would have 2 January-2009 on your spreadsheet. Have you checked for any problems like this?


Topic "How to arrange data in excel csv fromat"