¿Cómo hacer paneles de control de varias filas con JSL?Guardé el script para crear manualmente el panel en la tabla de datos y cerré la tabla de datos.
No se pudo reabrir la tabla y ejecutar el script.
¡Gracias expertos!
dt=Open("$SAMPLE_DATA/Big Class.jmp");
p1=dt<< Graph Builder(Transform Column("row",Formula(Row())),Size(500,100),Show Control Panel(0),Show Legend(0),Show Title(0),Show Footer(0),Show X Axis(0),Show Y Axis(0),Show X Axis Title(0),Show Y Axis Title(0),Variables(X(:row),Y(:height)),Elements(Line(X,Y,Legend(5))));
p2=dt<< Graph Builder(Transform Column("row",Formula(Row())),Size(500,100),Show Control Panel(0),Show Legend(0),Show Title(0),Show Footer(0),Show X Axis(0),Show Y Axis(0),Show X Axis Title(0),Show Y Axis Title(0),Variables(X(:row),Y(:weight)),Elements(Line(X,Y,Legend(5))));
Análisis y modelado de datos básicosventanasRe: ¿Cómo crear paneles de control de varias filas con JSL?Este es el JSL guardado
Graph Builder(
Size( 401, 40 ),
Show Control Panel( 0 ),
Show Legend( 0 ),
Show Title( 0 ),
Show Footer( 0 ),
Show X Axis( 0 ),
Show Y Axis( 0 ),
Show X Axis Title( 0 ),
Show Y Axis Title( 0 ),
Variables( X( Transform Column( "row", Formula( Row() ) ) ), Y( :weight ) ),
Elements( Line( X, Y, Legend( 5 ) ) )
)
Re: ¿Cómo crear paneles de control de varias filas con JSL?Si mi tabla de datos tiene 40 columnas y necesito crear este tipo de panel, ¿cómo lo guio?
¡Gracias!

Re: ¿Cómo crear paneles de control de varias filas con JSL?¿Es necesario utilizar Application Builder? Podría ser más fácil simplemente crear una nueva ventana y agregarle informes.
Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Big Class.jmp");
gb_expr = Expr(dt << Graph Builder(
Transform Column("row", Formula(Row())),
Size(500, 100),
Show Control Panel(0),
Show Legend(0),
Show Title(0),
Show Footer(0),
Show X Axis(0),
Show Y Axis(0),
Show X Axis Title(0),
Show Y Axis Title(0),
Variables(X(:row), Y(:height)),
Elements(Line(X, Y, Legend(5)))
));
lub = Lineup Box(N Col(1));
For(i = 1, i <= 10, i++,
lub << append(gb_expr)
);
nw = new window("",
lub
);Re: ¿Cómo crear paneles de control de varias filas con JSL?Gracias jthi!

Re: ¿Cómo crear paneles de control de varias filas con JSL?Sí pueden. La forma en que desee hacerlo depende de su aplicación; a continuación se muestra una opción que utiliza XPath
(nw << XPath("//OutlineBox[text() = 'Graph Builder']")) << Set Title("");Re: ¿Cómo crear paneles de control de varias filas con JSL?dt = Abrir("$SAMPLE_DATA/Big Class.jmp");
dt << Nueva columna( "col1", Numérico, Continuo, Establecer fórmula( Col Shuffle() ) );
dt << Nueva columna( "col2", Numérico, Continuo, Establecer fórmula( Col Shuffle() ) );
dt << Nueva columna( "col3", Numérica, Continua, Establecer fórmula( Col Shuffle() ) );
dt << Nueva columna( "col4", Numérica, Continua, Establecer fórmula( Col Shuffle() ) );
dt << Nueva columna( "col5", Numérica, Continua, Establecer fórmula( Col Shuffle() ) );
dt << Nueva columna( "col6", Numérico, Continuo, Establecer fórmula( Col Shuffle() ) );
dt << Nueva columna( "col7", Numérico, Continuo, Establecer fórmula( Col Shuffle() ) );
dt << Nueva columna( "col8", Numérica, Continua, Establecer fórmula( Col Shuffle() ) );
//??
gb_expr = Expr(dt << Generador de gráficos(
Transformar columna("fila", Fórmula(Fila())),
Tamaño(500, 100),
Mostrar panel de control(0),
Mostrar leyenda(0),
Mostrar título(0),
Mostrar pie de página(0),
Mostrar eje X (0),
Mostrar eje Y (0),
Mostrar título del eje X (0),
Mostrar título del eje Y (0),
Variables (X (: fila), Y (: altura)),
Elementos (Línea (X, Y, Leyenda (5)))
));
lub = Cuadro de alineación(N Col(1));
p2=dt<< Generador de gráficos(Transformar columna("fila",Fórmula(Fila())),Tamaño(500,100),Mostrar panel de control(0),Mostrar leyenda(0),Mostrar título(0),Mostrar pie de página( 0),Mostrar eje X(0),Mostrar eje Y(0),Mostrar título del eje X(0),Mostrar título del eje Y(0),Variables(X(:fila),Y(:peso)),Elementos( Línea(X,Y,Leyenda(5))));
(p2 << XPath("//OutlineBox[text() = '图形生成器']")) << Establecer título("");
lub = Cuadro de alineación(N Col(1));
lub << agregar(gb_expr)
……
nw = nueva ventana("",
lubricante
);
(nw << XPath("//OutlineBox[text() = 'Generador gráfico']")) << Establecer título("");
Re: ¿Cómo crear paneles de control de varias filas con JSL?Informe(plataforma)["Generador de gráficos"]

Re: ¿Cómo crear paneles de control de varias filas con JSL?Se puede ocultar, pero aún no se puede escribir varias columnas en JSL.

Re: ¿Cómo crear paneles de control de varias filas con JSL?Hay que ir un poco más despacio, explicar lo que necesitas en pequeños pasos. Actualmente, está solicitando varias cosas diferentes que tienen diferentes soluciones, ya que parece que el objetivo cambia un poco todo el tiempo (hace que proporcionar una solución sólida sea muy difícil).
Re: ¿Cómo crear paneles de control de varias filas con JSL?Sí, el código del experto prácticamente ha funcionado.
Acaba de agregar la columna "altura" 10 veces al tablero.
¿Cómo escribo código si quiero agregar un total de 10 columnas a la tabla, una por una, junto con las nuevas? Esa es la clave.
En cuanto al texto oculto es secundario.
¡Gracias expertos!
Re: ¿Cómo crear paneles de control de varias filas con JSL?Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Big Class.jmp");
dt << New Column("col1", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col2", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col3", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col4", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col5", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col6", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col7", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col8", Numeric, Continuous, Set Formula(Col Shuffle()));
create_report = function({dt, colname}, {Default Local},
gb = dt << Graph Builder(
Transform Column("row", Formula(Row())),
Size(500, 100),
Show Control Panel(0),
Show Legend(0),
Show Title(0),
Show Footer(0),
Show X Axis(0),
Show Y Axis(0),
Show X Axis Title(0),
Show Y Axis Title(0),
Variables(X(:row), Y(Eval(colname))),
Elements(Line(X, Y, Legend(5))),
SendToReport(
Dispatch({}, "Graph Builder", OutlineBox,
{Set Title(""), Image Export Display(Normal)}
)
)
);
return(gb);
);
lub = Lineup Box(N Col(1));
cols = {"col1", "col2", "col3", "col4", "col5", "col6", "col7", "col8"};
For Each({colname}, cols,
lub << Append(create_report(dt, colname));
);
nw = new window("",
lub
);Re: ¿Cómo crear paneles de control de varias filas con JSL?JSL Creación de gráficos ¿Cómo puedo hacer que los nombres de las columnas sean dinámicos y genéricos?De esta manera, la cantidad de columnas que agregué y los nombres de las columnas son diferentes
¡Gracias expertos!
dt = Open("$SAMPLE_DATA/Big Class.jmp");
dt << New Column("col1", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col2", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col3", Numeric, Continuous, Set Formula(Col Shuffle()));
p1=dt<< Graph Builder(
Size( 534, 648 ),
Show Control Panel( 0 ),
Show Legend( 0 ),
Show Title( 0 ),
Show Footer( 0 ),
Show X Axis( 0 ),
Show Y Axis( 0 ),
Show X Axis Title( 0 ),
Variables(
X( Transform Column( "Row", Formula( Row() ) ) ),
Y( :height ),
Y( :weight ),
Y( :col1 ),
Y( :col2 ),
Y( :col3 ),
Y( :col3 )
),
Elements( Position( 1, 1 ), Bar( X, Y, Legend( 10 ) ) ),
Elements( Position( 1, 2 ), Bar( X, Y, Legend( 9 ) ) ),
Elements( Position( 1, 3 ), Bar( X, Y, Legend( 8 ) ) ),
Elements( Position( 1, 4 ), Bar( X, Y, Legend( 7 ) ) ),
Elements( Position( 1, 5 ), Bar( X, Y, Legend( 6 ) ) ),
Elements( Position( 1, 6 ), Bar( X, Y, Legend( 5 ) ) )
);
Re: ¿Cómo crear paneles de control de varias filas con JSL?¿Siempre tienes la misma cantidad de gráficos? Si no, normalmente construyo las expresiones por separado (Variables() y Elementos) y luego uso Eval(Substitute()) para agregarlas a la expresión del generador de gráficos que finalmente evalúo. Sé que ha habido bastantes temas sobre esto ya que los respondí (simplemente no puedo encontrarlos), pero esta publicación de Xan da la idea básica.
Responder a todos: Cómo crear secuencias de comandos de contenido dinámico para Graph Builder
Re: ¿Cómo crear paneles de control de varias filas con JSL?dt = Open("$SAMPLE_DATA/Big Class.jmp");
dt << New Column("col1", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col2", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col3", Numeric, Continuous, Set Formula(Col Shuffle()));
vars = Expr(Variables(X(Transform Column("Row", Formula(Row())))));
points = Expr(Line(X, Y, Legend(5)));
起 = 4;止 = 8;
For(i = 起, i <= 止, i++,
Insert Into(vars, Eval Expr(Y(Expr(Column(dt, i)), Position(1))));
Insert Into( points, Eval Expr( Y( Expr( i - 起 + 1 ) ) ), i - 起 );
);
gb = Eval Expr(
Graph Builder(
Size(534, 648),
Show Control Panel(0),
Show Legend(0),
Show Title(0),
Show Footer(0),
Show X Axis(0),
Show Y Axis(0),
Show X Axis Title(0),
Expr(Name Expr(vars)),
points(Expr(Name Expr(points)))
)
);
gb;yo simplemente
¡Gracias expertos!
Re: ¿Cómo crear paneles de control de varias filas con JSL?Intenté escribirlo ayer, pero todavía no funcionó.
El problema con este código es la variable "dos".
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
dt << New Column( "col1", Numeric, Continuous, Set Formula( Col Shuffle() ) );
dt << New Column( "col2", Numeric, Continuous, Set Formula( Col Shuffle() ) );
dt << New Column( "col3", Numeric, Continuous, Set Formula( Col Shuffle() ) );
m1 = 1; m2 = 180; m0 = 10;
one=Expr(Variables( X( Transform Column( "Row", Formula( Row() ))) , Y( :height ) ));two=Expr(Elements( Position( 1, 1 ), Bar( X, Y, Legend( 5 ) ) ) );thr=Expr( Dispatch( {}, "height", ScaleBox, {Min( m1 ), Max( m2 ), Inc( m0 ), Minor Ticks( 1 )} ));
first co = 5;last col = 8;
For( i = first co, i <= last col, i++,
Insert Into( one, Eval Expr( Y( Expr( Column( dt, i ) ) ) ) );
Insert Into( two, Eval Expr(Elements( Position( 1, Expr(i-3 )), Bar( X, Y, Legend( Expr(1+i )) ) ) ));
Insert Into( thr, Eval Expr( Dispatch( {}, Column(Expr(i))<<GET name=""></GET><SPAN class=""><SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><span class="lia-inline-image-display-wrapper" image-alt="2024-07-18_17-44-45.png" style="width: 253px;"><img src="https://us.v-cdn.net/6038925/uploads/images/66319i838261FBE3A3DA44/2024-07-18_17-44-45.png" role="button" title="2024-07-18_17-44-45.png" alt="2024-07-18_17-44-45.png" /></span></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN>
Re: ¿Cómo crear paneles de control de varias filas con JSL?DE ACUERDO
Guarde el código de dibujo como un JSL separado
Por eso es fácil de combinar.
tx1 = "";
tx2 = "";
tx3 = "SendToReport(";
For( i = first co, i <= last col, i++,
//……
);
txt =
"nw=dt<< Graph Builder(Size(554,1654),Show Control Panel(0),Show Legend(0),Show Title(0),Show Footer(0),Show X Axis(0),Show Y Axis(0),Show X Axis Title(0),Variables(X(:分)"
|| tx1 || ")" || tx2 || "\!n," || tx3 ||
"));(nw << XPath(\!"//OutlineBox[text() = '图形生成器']\!")) << Set Title(\!"\!");nw<<SET window="" size=""></SET>Re: ¿Cómo crear paneles de control de varias filas con JSL?Índice de secuencias de comandos como ejemplos de Agregar variable y Agregar elemento
Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Big Class.jmp");
dt << New Column("col1", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col2", Numeric, Continuous, Set Formula(Col Shuffle()));
dt << New Column("col3", Numeric, Continuous, Set Formula(Col Shuffle()));
gb = dt << Graph Builder(
Size(534, 648),
Show Control Panel(0),
Show Legend(0),
Show Title(0),
Show Footer(0),
Show X Axis(0),
Show Y Axis(0),
Show X Axis Title(0),
Variables(
X(Transform Column("Row", Formula(Row()))),
Y(:height),
Y(:weight)
),
Elements(Position(1, 1), Bar(X, Y, Legend(10))),
Elements(Position(1, 2), Bar(X, Y, Legend(9)))
);
cols = {"col1", "col2", "col3", "col3"};
For Each({colname, idx}, cols,
gb << Add Variable({Eval(colname), Role("Y")});
// Either add both of these or neither
gb << Remove Element(1, 2 + idx, 1);
gb << Add Element(1, 2 + idx, {Type("Bar"), X, Y, Legend(9-idx)});
);
</CODE>Sometimes you have to check the graph builder script to see how it is being built. In this case due to Legend being starting from 10, you either have to first remove element and then add it back OR just let JMP take care of them (so leave out << Remove Element and << Add Element)</P>
<P><SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jthi_0-1721456186653.png" style="width: 400px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="jthi_0-1721456186653.png" style="width: 267px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="jthi_0-1721456186653.png" style="width: 267px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="jthi_0-1721456186653.png" style="width: 267px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="jthi_0-1721456186653.png" style="width: 267px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="jthi_0-1721456186653.png" style="width: 267px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="jthi_0-1721456186653.png" style="width: 267px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="jthi_0-1721456186653.png" style="width: 267px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="jthi_0-1721456186653.png" style="width: 267px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="jthi_0-1721456186653.png" style="width: 267px;"><span class="lia-inline-image-display-wrapper" image-alt="jthi_0-1721456186653.png" style="width: 267px;"><img src="https://us.v-cdn.net/6038925/uploads/images/66331i8F2B15E24DF276BB/jthi_0-1721456186653.png" role="button" title="jthi_0-1721456186653.png" alt="jthi_0-1721456186653.png" /></span></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></P>
<PRE><CODE class=" language-jsl">Graph Builder(
Transform Column("Row", Formula(Row())),
Size(534, 648),
Show Control Panel(0),
Show Legend(0),
Show Title(0),
Show Footer(0),
Show X Axis(0),
Show Y Axis(0),
Show X Axis Title(0),
Variables(
X(:Row),
Y(:height),
Y(:weight),
Y(:col1),
Y(:col2),
Y(:col3),
Y(:col3)
),
Elements(Position(1, 1), Bar(X, Y, Legend(10))),
Elements(Position(1, 2), Bar(X, Y, Legend(9))),
Elements(Position(1, 3), Bar(X, Y, Legend(8))),
Elements(Position(1, 4), Bar(X, Y, Legend(7))),
Elements(Position(1, 5), Bar(X, Y, Legend(6))),
Elements(Position(1, 6), Bar(X, Y, Legend(5)))
);
Re: ¿Cómo crear paneles de control de varias filas con JSL?¡Gracias expertos!
Establecí más condiciones en la aplicación real.
Me gusta este formulario. Todavía no sé cómo agregar varias columnas después del hecho.
ca = "row";dt = New Table( "test", Add Rows( 40 ), New Column( ca, Character, "Nominal" ) );
Column( ca ) << Formula( Char( Row() ) );dt << run formulas;Column( ca ) << deleteFormula;
na = {"A", "B", "C", "D", "E"};
j = 1;
For( j = 1, j <= N Items( na ), j++,
i = 1;
For( i = 1, i <= 4, i++,
ca = na[j] || Char( i ); New Column( ca );
Column( ca ) << Formula( If( i == 1, Random Integer( -100, 100 ), Random Integer( 30 * i, 50 * i ) ) );
dt << run formulas; Column( ca ) << deleteFormula; Column( ca ) << Set Display Width( 38 );
);
);
p1=dt<<GRAPH builder=""></GRAPH><BR />Illustration:<BR />A1-A4 is a group of the same letters, are listed as a group of 4, move A2-A4 to the right of the Y axis to form a line graph;A1 is the bar chart,<BR />The color of the bar is variable, but the color of the line on the right is fixed by number (the same color as the line with different letter groups of the number).<BR />The graphics are set to transparency.The right Y-axis title is also hidden.<BR />So there's a lot more code for mapping.I don't know how to batch them.
Thanks!
<SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="2024-07-22_16-07-12.png" style="width: 999px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-22_16-07-12.png" style="width: 999px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-22_16-07-12.png" style="width: 999px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-22_16-07-12.png" style="width: 999px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-22_16-07-12.png" style="width: 999px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-22_16-07-12.png" style="width: 999px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-22_16-07-12.png" style="width: 999px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-22_16-07-12.png" style="width: 999px;"><SPAN class="lia-inline-image-display-wrapper" image-alt="2024-07-22_16-07-12.png" style="width: 999px;"><span class="lia-inline-image-display-wrapper" image-alt="2024-07-22_16-07-12.png" style="width: 999px;"><img src="https://us.v-cdn.net/6038925/uploads/images/66366iA37DF0093E9320C8/2024-07-22_16-07-12.png" role="button" title="2024-07-22_16-07-12.png" alt="2024-07-22_16-07-12.png" /></span></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN>
Re: ¿Cómo crear paneles de control de varias filas con JSL?Si el número de series en el gráfico es mayor a 200, no sé cómo cambia

Re: ¿Cómo crear paneles de control de varias filas con JSL?Utilizar la tabla de datos apilados facilita la creación de algo como esto

Re: ¿Cómo crear paneles de control de varias filas con JSL?Lo intenté, pero no pude descubrir cómo apilarlo.
Pídele instrucciones a un experto.
¡Muchas gracias!
Re: ¿Cómo crear paneles de control de varias filas con JSL?Usar pila de series múltiples

Luego cree una columna de agrupación a partir de una de las columnas de etiquetas, cambie el nombre de las columnas según sea necesario, elimínelas según sea necesario y cree un gráfico.
Re: ¿Cómo crear paneles de control de varias filas con JSL?OK veo
Gracias jthi!
Re: ¿Cómo crear paneles de control de varias filas con JSL?Esta creación de grupos de gráficos parece ser la configuración predeterminada para muchos sistemas.
Por ejemplo, la columna de etiqueta en este gráfico es el orden predeterminado
¿Quiero que el gráfico se ordene por la etiqueta de la tabla de datos original y solo pueda numerarse en la columna de etiqueta de la tabla de datos?Por ejemplo, las etiquetas en la tabla de datos están ordenadas por C, D, A, B, E, y los gráficos también están ordenados por esto, que solo se puede modificar en la tabla de datos a: 1C, 2D, 3A, 4B, 5E.
Establecer transparencia también es ineficaz.
¡Gracias!

Re: ¿Cómo crear paneles de control de varias filas con JSL?Utilice la propiedad de la columna Orden de valor para realizar el pedido.