Finding Invisible Variables

Use this forum to post Vensim related questions.
Post Reply
DonnaDarko
Junior Member
Posts: 2
Joined: Tue Apr 24, 2007 5:22 pm

Finding Invisible Variables

Post by DonnaDarko »

Hello,

I am a fairly new Vensim user. There are some variables (in the program I inherited) that I can no longer seem to find, but that cause the program to crash when I try to simulate it. I already tried View --> show hidden, but this didnt work. When I view the model as a text file, however, then I can find them again. However, deleting within the text file doesn't seem to solve the problem either.
Does anyone have an idea how to solve this?
Thanks!!
Administrator
Super Administrator
Posts: 4590
Joined: Wed Mar 05, 2003 3:10 am

Post by Administrator »

Use the "Model Variable" sketch tool (as shown in
http://www.vensim.com/documentation/html/20130.htm)
to add the offending variable to the sketch. Then you can look at it's equations, influences etc.

Hope this helps.

Tony.
DonnaDarko
Junior Member
Posts: 2
Joined: Tue Apr 24, 2007 5:22 pm

ghost variable

Post by DonnaDarko »

Hi Tony,

It totally helped!!! Such an easy solution, and I tried all the hard ones first!
One more question, following the first. Assuming there are more "ghost variables" that I dont know about, probably because they weren't properly deleted after being discarded, is there a way to find them (so practically those variables which exist in the program, but are not visible in any of the views) without searching for each individually? I am asking because we must have several hundred variables in our program. So of course this is a possibility, but if there is a better one, then I would like to know about it!

Thanks so much!
Ursula
LAUJJL
Senior Member
Posts: 1427
Joined: Fri May 23, 2003 10:09 am
Vensim version: DSS

Deleting ghost variables

Post by LAUJJL »

Hi Ursula

I join a very simple model called try.mdl
It has two constants, try and try2.
Try is visible, try2 is not visible.
you want to delete the one not visible.
To delete it you go to view and go to as text.
When in the text version, you delete the equation relative to
try2, not forgetting any characters, in particular the last vertical mark.
Then staying in text mode, you save the model to a new model say try2 and go back to sketch mode.
The try variable will still be showing and if you go either to the equation editor or to any tool listing variables, you will notice that try2 has disappeared.
The same procedure should work with any number of variables.
Regards.
JJ
Attachments
try.mdl
(1.06 KiB) Downloaded 393 times
bob@vensim.com
Senior Member
Posts: 1107
Joined: Wed Mar 12, 2003 2:46 pm

Post by bob@vensim.com »

In the variable selection control - or using the Model Variable tool - one of the variable types in the dropdown is Orphan - those are variables that do not appear on any sketch.
Post Reply