X-Y plot not X-t

Use this forum to post Vensim related questions.
Post Reply
majidshafieejood
Junior Member
Posts: 11
Joined: Wed Aug 31, 2011 9:46 am

X-Y plot not X-t

Post by majidshafieejood »

I was just wondering if it is possible to plot one variable vs another in Vensim? For example all the time when I want to plot x-y graph, I need to export the data set and plot it in excel! In dynamic analysis, sometimes we need the plot of two variables to get see hysteresis!

thanks,

Majid,
Administrator
Super Administrator
Posts: 4592
Joined: Wed Mar 05, 2003 3:10 am

Re: X-Y plot not X-t

Post by Administrator »

Using custom graphs you can set the x axis to something different.

http://www.vensim.com/documentation/ind ... custom.htm
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
majidshafieejood
Junior Member
Posts: 11
Joined: Wed Aug 31, 2011 9:46 am

Re: X-Y plot not X-t

Post by majidshafieejood »

Thanks
majidshafieejood
Junior Member
Posts: 11
Joined: Wed Aug 31, 2011 9:46 am

Re: X-Y plot not X-t

Post by majidshafieejood »

Hi again,

I have another problem hoping you can help me with that.

I have different plots. some of them are plots of state variables (say X or Y vs Time) versus time. Others are plots of state variables versus each other (say X vs Y). Is it possible to have different time spans for these plots. I mean for example for the first group of plots, I would like to have a plot starting from time=0, but for the second group, I want to ignore the first few steps (the plots starting from time=50).

Thanks,
Administrator
Super Administrator
Posts: 4592
Joined: Wed Mar 05, 2003 3:10 am

Re: X-Y plot not X-t

Post by Administrator »

x-min and x-max in the custom dialog definitions will let you do this.
http://www.vensim.com/documentation/ind ... ?23930.htm
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
tomfid
Administrator
Posts: 3811
Joined: Wed May 24, 2006 4:54 am

Re: X-Y plot not X-t

Post by tomfid »

Another possibility is to create reporting variables that suppress a portion of a variable's history. For example:

reported x = IF THEN ELSE( Time >= threshold, x, :NA: )
majidshafieejood
Junior Member
Posts: 11
Joined: Wed Aug 31, 2011 9:46 am

Re: X-Y plot not X-t

Post by majidshafieejood »

The First reply is not what I am looking for. But the second one is a very wise idea.
Awesome.
Thanks
majidshafieejood
Junior Member
Posts: 11
Joined: Wed Aug 31, 2011 9:46 am

Re: X-Y plot not X-t

Post by majidshafieejood »

Hello again,

I wanted to send a new post but I could not! So I am following my previous post.

I wanted to generated Gaussian white noise in Vensim (I am using PLE but I don't think it matters!)

So basically I need to use Random Normal distribution. Now the question is if in this function, the randomly generated values are uncorrelated or not. Since I can handle mean zero and finite standard deviation in Vensim but I couldn't find anywhere that the randomly generated values are uncorrelated. This is crucial for any type of white noise.

Thanks,

Majid,
tomfid
Administrator
Posts: 3811
Joined: Wed May 24, 2006 4:54 am

Re: X-Y plot not X-t

Post by tomfid »

They are uncorrelated, as are draws from any of the RANDOM functions.

Completely uncorrelated white noise is actually not physically realizable, because it would have infinite power at high frequencies. So, you either need to ensure that your noise is sampled at some fixed interval, or implement a cutoff frequency, as in pink noise. See http://models.metasd.com/pink-noise/

One way to ensure fixed sampling is to not change your TIME STEP, but that prevents tests for numerical stability. Better to use SAMPLE IF TRUE with PULSE TRAIN or the PINK NOISE macro above.
majidshafieejood
Junior Member
Posts: 11
Joined: Wed Aug 31, 2011 9:46 am

Re: X-Y plot not X-t

Post by majidshafieejood »

Thank you very much.
Post Reply