cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Learn how to build custom Python data connectors and further customize JMP’s Data Connector Framework with the Python Data Connector Demo, available now in the JMP Marketplace!
  • See how to create experiments to support product design and ID useful product features. Register for June 12 webinar, 2pm US Eastern Time.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
Jackie_
Level VI

Get Y axis column name from the variability chart

Hi,

 

Is there a way to get the Y axis column name from the variability? I tried using get Y axis but doesn't work. Any suggestions?

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Variability Data/2 Factors Crossed.jmp" );
obj = dt << Variability Chart( Y( :Measurement ), X( :Operator, :part# ) );

ax = obj << get y axis;
Show( ax );

chart

 

 

2 ACCEPTED SOLUTIONS

Accepted Solutions
txnelson
Super User

Re: Get Y axis column name from the variability chart

Here is one way to get the Y column name

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Variability Data/2 Factors Crossed.jmp" );
obj = dt << variability chart( Y( :Measurement ), X( :Operator, :part# ) );

// Parse the returned script to find the specified Y column
theYColumn = Word(
	1,
	Substr( Char( obj << get script ), Contains( Char( obj << get script ), "Y(:" ) + 3 ),
	"),"
);
Jim

View solution in original post

jthi
Super User

Re: Get Y axis column name from the variability chart

Column name is in at least four different places:

  • Your creation script
  • Three times in the report
    • Variability Gauge Analysis for Measurement
    • Variability Chart for Measurement
    • And Y-axis

Is there a specific reason to get it from Y-axis which is most likely the most difficult one?

Names Default To Here(1);

dt = Open("$SAMPLE_DATA/Variability Data/2 Factors Crossed.jmp");

var = dt << Variability Chart(Y(:Measurement), X(:Operator, :part#));

yaxis_text = Report(var)["Variability Chart for Measurement", Text Box(1)] << get text;
-Jarmo

View solution in original post

4 REPLIES 4
txnelson
Super User

Re: Get Y axis column name from the variability chart

Here is one way to get the Y column name

Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Variability Data/2 Factors Crossed.jmp" );
obj = dt << variability chart( Y( :Measurement ), X( :Operator, :part# ) );

// Parse the returned script to find the specified Y column
theYColumn = Word(
	1,
	Substr( Char( obj << get script ), Contains( Char( obj << get script ), "Y(:" ) + 3 ),
	"),"
);
Jim
jthi
Super User

Re: Get Y axis column name from the variability chart

Column name is in at least four different places:

  • Your creation script
  • Three times in the report
    • Variability Gauge Analysis for Measurement
    • Variability Chart for Measurement
    • And Y-axis

Is there a specific reason to get it from Y-axis which is most likely the most difficult one?

Names Default To Here(1);

dt = Open("$SAMPLE_DATA/Variability Data/2 Factors Crossed.jmp");

var = dt << Variability Chart(Y(:Measurement), X(:Operator, :part#));

yaxis_text = Report(var)["Variability Chart for Measurement", Text Box(1)] << get text;
-Jarmo
Jackie_
Level VI

Re: Get Y axis column name from the variability chart

I am trying to create an interactive plot with radio buttons and column switchers. For that I need to get column names in the current Y axis VC to be able to replace columns in the column switcher

Jackie_
Level VI

Re: Get Y axis column name from the variability chart

Thanks Jim and Jarmo!

Recommended Articles