NX = 5; //NX NY are to specify the matrix indices for Graph builder
NY = 5;
If( Is Missing(colX1[i]), NX = NX - 1 );
If( Is Missing(colX2[i]), NX = NX - 1 );
If( Is Missing(colX3[i]), NX = NX - 1 );
If( Is Missing(colX4[i]), NX = NX - 1 );
show(NX);
If( Is Missing(colY1[i]), NY = NY - 1 );
If( Is Missing(colY2[i]), NY = NY - 1 );
If( Is Missing(colY3[i]), NY = NY - 1 );
If( Is Missing(colY4[i]), NY = NY - 1 );
show(NY);
x_vars = {}; // make empty list for x and y variables
y_vars = {};
X = colX[i];
X1 = colX1[i];
X2 = colX2[i];
X3 = colX3[i];
X4 = colX4[i];
Y = colY[i];
Y1 = colY1[i];
Y2 = colY2[i];
Y3 = colY3[i];
Y4 = colY4[i];
If( !Is Missing(colX[i]), Insert Into( x_vars, X ) );
If( !Is Missing(colX1[i]), Insert Into( x_vars, X1) );
If( !Is Missing(colX2[i]),Insert Into( x_vars, X2) );
If( !Is Missing(colX3[i]), Insert Into( x_vars, X3) );
If( !Is Missing(colX4[i]), Insert Into( x_vars, X4) );
If( !Is Missing(colY[i]), Insert Into( y_vars, Y) );
If( !Is Missing(colY1[i]), Insert Into( y_vars, Y1) );
If( !Is Missing(colY2[i]), Insert Into( y_vars, Y2) );
If( !Is Missing(colY3[i]), Insert Into( y_vars, Y3) );
If( !Is Missing(colY4[i]), Insert Into( y_vars, Y4) );
show(x_vars);
show(y_vars);
GB = Current Data Table() << Graph Builder(
Size( 621, 472 ),
Variables(
X(x_vars),
Y(y_vars)
),
// the for loops is used together with the NX and NY part from above
For( i = 1, i <= NX, i++,
For( j = 1, j <= NY , j++,
If( i == 1 & j == 1,
Elements(
Position( i, j ),
Points( X, Y, Legend( 67 ) ),
Smoother( X, Y, Legend( 68 ) )
),
Elements(
Position( i, j ),
Points( X, Y, Legend( 68 + (i - 1) * 5 + (j - 2) ) ),
Smoother( X, Y, Legend( 69 + (i - 1) * 5 + (j - 2) ) )
)
)
)
),
SendToReport(
Dispatch(
{},
"Graph",
ScaleBox,
{Label Row( {Show Major Grid( 1 ), Show Minor Grid( 1 )} )}
)
)
);Hallo zusammen, wie kann ich es so skripten, dass es erkennt, welche meiner Variablen nicht leer ist, und es in die unten gezeigten Variablen X( ) und Y( ) einfügt.
Was ich jetzt habe, ist oben gezeigt, wo es erkennt, was nicht fehlt, und es zu einer Liste hinzufügt, und dann aus dieser Liste versucht, es zu den unten gezeigten Variablen hinzuzufügen, wie mache ich weiter?
danke fürs Lesen
Variables(
X(x_vars),
Y(y_vars)
),