Help with model calibration
-
- Super Administrator
- Posts: 4603
- Joined: Wed Mar 05, 2003 3:10 am
Re: Help with model calibration
Please upload a XLSX file (XLS can contain macros).
And can you convert the data you have so it matches the Vensim example?
And can you convert the data you have so it matches the Vensim example?
Advice to posters seeking help (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Units are important!
http://www.bbc.co.uk/news/magazine-27509559
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Units are important!
http://www.bbc.co.uk/news/magazine-27509559
Re: Help with model calibration
I've uploaded the xlsx file
Vensim format: Is it like this?
Driver1 Time 1 2 3 4 5 6
Variable1 data data data data
Variable2 data data data data
Driver2
Time
Variable1 data data data data
Variable2 data data data data
Thanks so much for all your help
Vensim format: Is it like this?
Driver1 Time 1 2 3 4 5 6
Variable1 data data data data
Variable2 data data data data
Driver2
Time
Variable1 data data data data
Variable2 data data data data
Thanks so much for all your help
- Attachments
-
- icdata2.xlsx
- (9.9 KiB) Downloaded 179 times
Re: Help with model calibration
You could reformat your data that way, but it's easier to import it as tidy data.
I've attached an example.
I've attached an example.
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
In the example:
- see the spreadsheet driver_data tab of the .csv file for the required format
- the command script import.cmd can be used to import the data
- the model uses the data to calculate a Poisson likelihood from an expected (constant) error rate per driver
- see the spreadsheet driver_data tab of the .csv file for the required format
- the command script import.cmd can be used to import the data
- the model uses the data to calculate a Poisson likelihood from an expected (constant) error rate per driver
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
Thanks so much for all your help.
This is more complex than I thought.
I'm still unable to load the data.
This is what I did:
Model>Import Dataset> then I chose the name of the csv file. It did not work
This is more complex than I thought.
I'm still unable to load the data.
This is what I did:
Model>Import Dataset> then I chose the name of the csv file. It did not work
Re: Help with model calibration
How is the command script import.cmd used?
Re: Help with model calibration
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
I'm sorry I'm not getting this thing. You have done everything you can and I really appreciate. I guess I'm totally lost, I don't have a background in computer science
You have attached 3 different files: data.csv, data.xlsx, data.vdf
I don't even know how you went from the excel file to the vdf format.
Could you please pick the csv or xlsx file (which I'm familiar with) and explain how to load the data in lay terms? Remember I have my model built in Vensim and want to load the data to the model
I was able to load the vdf into the software but it opened in a different window. I could not integrate it to the model. Also, it would be a learning for me, if you use the csv or xlsx and explain how to load the data to my model in very lay terms.
Again, I'm sorry I have been using a lot of your time
You have attached 3 different files: data.csv, data.xlsx, data.vdf
I don't even know how you went from the excel file to the vdf format.
Could you please pick the csv or xlsx file (which I'm familiar with) and explain how to load the data in lay terms? Remember I have my model built in Vensim and want to load the data to the model
I was able to load the vdf into the software but it opened in a different window. I could not integrate it to the model. Also, it would be a learning for me, if you use the csv or xlsx and explain how to load the data to my model in very lay terms.
Again, I'm sorry I have been using a lot of your time
Re: Help with model calibration
Don't be hard on yourself - it's complex.
Use File>Edit File to load the import.cmd script.
Then use File>Run Commands to make the conversion.
For tidy data, the format is always:
- columns with subscripts
- a Time column
- columns of data with variable names in the header row
Use File>Edit File to load the import.cmd script.
Then use File>Run Commands to make the conversion.
For tidy data, the format is always:
- columns with subscripts
- a Time column
- columns of data with variable names in the header row
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
I did what you described. I don't know if it worked. When I double checked the data loaded, I realize they are different from the data I have. So, I don't know.
I emailed you the model, please check if it really loaded
I emailed you the model, please check if it really loaded
Re: Help with model calibration
Different how?
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
I clicked on monthly driving in the model, then clicked on graph to check the numbers. But based on what you said, the data is not in the model. So those numbers were not the data.
It seems like the model itself cannot run anymore. I guess I did something wrong. How can I delete/remove the subscript? I would like to start over again
It seems like the model itself cannot run anymore. I guess I did something wrong. How can I delete/remove the subscript? I would like to start over again
Re: Help with model calibration
We need a little more information here.
- What happens when you load the import.cmd script?
- Have you loaded the resulting data.vdf?
- What error message do you get when you try to run the model?
- Can you revert to an earlier version of the model (like the one you emailed)?
- What happens when you load the import.cmd script?
- Have you loaded the resulting data.vdf?
- What error message do you get when you try to run the model?
- Can you revert to an earlier version of the model (like the one you emailed)?
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
When I followed what you described, I got this "MENU>TIDY2VDF|data.csv" in the editor. I don't know where is the data because I don't see anything else other than "MENU>TIDY2VDF|data.csv" in a blank page. I then clicked on a variable in the model, then clicked on graph to check, but I saw numbers different from the data.
Like I said before I don't have a background in computer science; so it would be really helpful for me if things are explained in very lay terms.
When I tried to simulate the model it says model has errors and cannot be simulated. I've tried different approaches (including GET XLS DATA) to import the data, I guess I may have done some wrong. I can revert the model if I know how to remove/delete the subscript I set up
Like I said before I don't have a background in computer science; so it would be really helpful for me if things are explained in very lay terms.
When I tried to simulate the model it says model has errors and cannot be simulated. I've tried different approaches (including GET XLS DATA) to import the data, I guess I may have done some wrong. I can revert the model if I know how to remove/delete the subscript I set up
Re: Help with model calibration
Did you use file>run commands? Running the script will translate data.csv to data.vdf. To see the data, you need data.vdf loaded in the Dataset Control.
https://www.vensim.com/documentation/in ... tasets.htm
Check out
http://vensim.com/building-a-simple-vensim-model/
http://vensim.com/causal-tracing-in-vensim/
http://vensim.com/model-analysis-world-dynamics/
for more basic Vensim skills.
When a model has errors, the equation editor will tell you what the specific errors are. We can't help further without knowing that.
You should remove any GET XLS statements from your model, if you're not using them.
https://www.vensim.com/documentation/in ... tasets.htm
Check out
http://vensim.com/building-a-simple-vensim-model/
http://vensim.com/causal-tracing-in-vensim/
http://vensim.com/model-analysis-world-dynamics/
for more basic Vensim skills.
When a model has errors, the equation editor will tell you what the specific errors are. We can't help further without knowing that.
You should remove any GET XLS statements from your model, if you're not using them.
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
Thanks for sending these videos, I think they are very helpful.
I've attached what I got when I used the file>run commands
I would like to delete/remove the array and start over. Any suggestions on how I can delete the array?
I've attached what I got when I used the file>run commands
I would like to delete/remove the array and start over. Any suggestions on how I can delete the array?
- Attachments
-
- Doc1.docx
- (35.44 KiB) Downloaded 175 times
Re: Help with model calibration
Look at this as well
- Attachments
-
- Doc2.docx
- (92.83 KiB) Downloaded 169 times
Re: Help with model calibration
I think you're trying to use the Model>Import dataset commands on the import.cmd script. That won't work.
Use File>Edit File to load the import.cmd script into the built-in text editor.
Then use File>Run Commands to import the data.
If your source data is called somefile.csv, the result will be named somefile.vdf (unless you change the arguments to the TIDY2VDF command).
Use File>Edit File to load the import.cmd script into the built-in text editor.
Then use File>Run Commands to import the data.
If your source data is called somefile.csv, the result will be named somefile.vdf (unless you change the arguments to the TIDY2VDF command).
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
Removing subscripts can be messy. There are several ways:
1. use a text editor to search & replace all instances of [driver] with nothing.
2. use the equation editor to visit all the equations and remove the driver references one at a time.
3. select the variables in question on the diagram, then use the Edit>Set Subscripts menu with the "Removing" option.
After you've removed all the driver references, you can delete the subscript equation itself.
1. use a text editor to search & replace all instances of [driver] with nothing.
2. use the equation editor to visit all the equations and remove the driver references one at a time.
3. select the variables in question on the diagram, then use the Edit>Set Subscripts menu with the "Removing" option.
After you've removed all the driver references, you can delete the subscript equation itself.
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
I did exactly what you said. I used File>Edit File. I did not use Model>Import dataset commands at all. It's kind of strange that it's so hard to load data into the software
Re: Help with model calibration
It shouldn't be hard at all. The symptom here is that your empty dataset is called "import.vdf" not "data.vdf". That suggests that the source file was import.xxx (xxx = tab, csv, etc.) rather than data.csv
What version are you using? TIDY2VDF is a fairly new feature (6.3 or 6.4, I think) so it's possible that older versions misinterpret the command.
What version are you using? TIDY2VDF is a fairly new feature (6.3 or 6.4, I think) so it's possible that older versions misinterpret the command.
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
I'm using the newer version (6.4).
I removed the subscripts and put them back again. The model is OK now.
I think the problem is probably me, I'm missing some basic steps.
1) Let's say the name of the dataset I'm trying to import is data.csv
2) Then I used File>Edit file and selected the file "data.csv". I could see the data loaded in the text editor.
3) Then I used File, and I don't see Run Commands anymore
If I followed what you said:
1) I used File>Edit file and selected the file "import.cmd". I could see MENU>TIDY2VDF|data.csv in the text editor. Where is the import.cmd coming from? I downloaded it from the example you attached and sent to me. So I don't know if that's what I should directly use
2) Then I used File>Run Commands and got the empty dataset I attached to you
I removed the subscripts and put them back again. The model is OK now.
I think the problem is probably me, I'm missing some basic steps.
1) Let's say the name of the dataset I'm trying to import is data.csv
2) Then I used File>Edit file and selected the file "data.csv". I could see the data loaded in the text editor.
3) Then I used File, and I don't see Run Commands anymore
If I followed what you said:
1) I used File>Edit file and selected the file "import.cmd". I could see MENU>TIDY2VDF|data.csv in the text editor. Where is the import.cmd coming from? I downloaded it from the example you attached and sent to me. So I don't know if that's what I should directly use
2) Then I used File>Run Commands and got the empty dataset I attached to you
Re: Help with model calibration
Thanks for laying out the steps exactly. Not sure how this could be happening.
1) Let's say the name of the dataset I'm trying to import is data.csv
2) Then I used File>Edit file and selected the file "data.csv". I could see the data loaded in the text editor. CORRECT
3) Then I used File, and I don't see Run Commands anymore CORRECT - you won't see Run Commands unless the file has extension .cmd
If you're using 6.4 instead of the latest 6.4e, that could be the problem. Do you get any errors/warnings when the empty dataset is created?If I followed what you said:
1) I used File>Edit file and selected the file "import.cmd". I could see MENU>TIDY2VDF|data.csv in the text editor. CORRECT Where is the import.cmd coming from? It's a script that I created. I downloaded it from the example you attached and sent to me. So I don't know if that's what I should directly use As long as the data file name matches, you can use my copy; otherwise just edit to match.
2) Then I used File>Run Commands and got the empty dataset I attached to you
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
I'd try upgrading to 6.4e before doing anything else.
As an interim measure, you can use the data.vdf in the .zip file I posted. It will be compatible.
As an interim measure, you can use the data.vdf in the .zip file I posted. It will be compatible.
/*
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Advice to posters (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391
Blog: http://blog.metasd.com
Model library: http://models.metasd.com
Bookmarks: http://delicious.com/tomfid/SystemDynamics
*/
Re: Help with model calibration
Sorry for the confusion, I think I'm using the latest version 6.4E(x32).
I don't know what's wrong. I've attached what I got, which is what I have been getting. What should I expect to see when I click on OK?
I don't know what's wrong. I've attached what I got, which is what I have been getting. What should I expect to see when I click on OK?
- Attachments
-
- Doc3.docx
- (108.33 KiB) Downloaded 118 times