Bivariate list conditionhi
I'm looking for a condition to start a loop that handles the Bivariate title,
I found one that works only if I have more the 1 chart.
lst = dt << Bivariate(
.
.
.
.
);
If(IsList(lst) & (nn = NItems(lst)),
For(i = 1, i <= nn, i++,
.
.
.
.
);
I cant find a condition to distinguish between 0 (no chart == dt table is empty) to 1 (only one chart is created).
any help is welcomed
Re: Bivariate list conditionOk! so that can definitely help.
Thanks!
Re: Bivariate list conditionThe Try() function can be used in many, many ways to keep code from failing, and also to determine is code was properly executed. Here is just one simple way to illustrate it's use
Names Default To Here( 1 );
dis = Try(
dt << Distribution( Continuous Distribution( Column( :height ) ) ),
"not found"
);
If( dis == "not found",
Dialog( "No Table Produced" )
);
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dis = Try(
dt << Distribution( Continuous Distribution( Column( :height ) ) ),
"not found"
);
If( dis == "not found",
Dialog( "No Table Produced" )
);
Re: Bivariate list conditionthanks, Jim
Eventually I used a simple condition Nrows(dt) > 0 to check if the table is empty, not the smartest one but it works.
how can i use the try() function to check if i have 1 or 0 charts in my parameter "lst" ?
Re: Bivariate list conditionYour description is a bit vague to suggest specific solutions. I suggest you look into
isEmpty(),
N Cols()
and
Try()
as potential functions that can detect the missing charts.