Hi All,
I'm noticing that the Distribution platform doesn't seem to accept column references in the same way that Graph Builder does, for example.
I have code where I am referencing different columns within a data table using the Column(dtname, number) format. For example, this is a bit of code where I do it with GB and it works just fine:
Graph Builder(
Size( 500, 350 ),
Show Control Panel( 0 ),
Variables(
X( Column( dt_results, NNxcol ) ),
Y( Column( dt_results, NNYCol + N Items( NNXList ) ) ),
Y( Column( dt_results, NNYCol + 1 + N Items( NNXlist ) ), Position( 1 ) ),
Y( Column( dt_results, NNYCol + 2 + N Items( NNXList ) ) )
),
Elements(
Position( 1, 1 ),
Points( X, Y( 1 ), Y( 2 ), Legend( 8 ) ),
Smoother( X, Y( 1 ), Y( 2 ), Legend( 9 ) )
),
Elements( Position( 1, 2 ), Points( X, Y, Legend( 10 ) ), Smoother( X, Y, Legend( 11 ) ) ),
SendToReport(
Dispatch(
{},
"graph title",
TextEditBox,
{Set Text( NNYList[NNYCol] || " Stats vs. " || NNXList[NNxcol] )}
),
Dispatch( {}, "Y title", TextEditBox, {Set Text( NNYList[NNYCol] || " Train & Valid" )} )
)
)
However, when I try to do something similar in the Distribution platform, nothing happens, and I think it's because the Continuous Distribution() call doesn't seem to like referencing a column this way. It seems to like referencing the column as Column(column name).
Distribution(
Continuous Distribution( Column( dt_results, NNYCol + NNcolshift ), Quantiles( 0 ) ),
Continuous Distribution( Column( dt_results, NNYCol + 1 + NNcolshift ), Quantiles( 0 ) ),
Continuous Distribution( Column( dt_results, NNYCol + 2 + NNcolshift ), Quantiles( 0 ) )
)
I want to use variables when I call the platform because it's more flexible in the code rather than hard-coding in the column name itself. Any idea why the Distribution platform behaves differently or how to correctly reference the column so I get the intended output?
Any thoughts/comments are appreciated.
Thanks!,
DS