Hello all,
I am using label in my script to help me filter data. The script is showing bellow:
dt_daily << New Column( "Outliers Exclusion (Energy % from Controls)",
Numeric,
Continuous,
Formula( If( !labeled( Row State() ) , "Clean Bad Data", "Show Bad Data" ) ),
eval formula
);
Close( dt_subdaily );
Close( dt_dailysplit );
Wait( 0 );
New Window( "Energy % from Controls",
dt_daily << Graph Builder(
Size( 800, 500 ),
Show Control Panel( 0 ),
Variables( X( :Date ), Y( :Name( "Energy % from Controls" ) ), Group X( :SiteName ), Group Y( :Sequence ), Overlay( :SampleDescription ) ),
Elements( Position( 1, 1 ), Points( X, Y, Legend( 16 ) ), Smoother( X, Y, Legend( 17 ) ) ),
//Button Box( "Include Bad Data" ,Row State() = Excluded State( 0 )),
Local Data Filter(
Auto clear( 0 ),
Add Filter(
columns(
:name( "Outliers Exclusion (Energy % from Controls)" ),
:SiteName,
:Sequence,
:SampleDescription,
:EquipmentName,
:TableRank,
:Name( "Energy % from Controls" ),
:Date
),
Where( :Name( "Energy % from Controls" ) >= -0.04 & :PPI_AH <= 0.06 ),
//if ( :name("Outliers Exclusion (Energy % from Controls)") == "Clean Bad Data", Row State() = Excluded State( 0 ))
),
SendToReport(
Dispatch( {}, "Date", ScaleBox, {Format( "m/d/y", 7 ), Label Row( {Show Major Grid( 1 ), Show Minor Grid( 1 )} )} ),
Dispatch(
{},
"Energy % from Controls",
ScaleBox,
{/*Min( -0.04 ), Max( 0.06 ), Inc( 0.01 ), Minor Ticks( 1 ),*/
//Format( "Percent", 9, 1 ), Max( 0.01 ),
Add Ref Line( 0, "Solid", "Black", "", 1 ), Label Row( {Show Major Grid( 1 ), Show Minor Grid( 1 )} )}
)
)
)
)
);
However, I don't want those number showing up. Is there any way that I can keep the labels for rows in data table but remove the numbers of lables from graphs?

Thanks a lot if someone can help!
Thank you so much for your help! It is extremly helpful!!! I appreciate it a lot.
Best,
Winnie
Winnie,
JMP allows data columns to act as labels, AND allows rows to be labeled. When rows are labeled, the values of the labels appear on the graph. If there are no label columns then the row numbers appear on the graph.
Since I do not have your table, review the script below. It:
- randomly selects 10 rows and marks them as labeled
- draws the graph and note those labeled columns now show names
- removes the column :name as a label, so the graph now shows row numbers
- then shows several alternative options.
Be careful when using formulas with row state functions. If a user or you accidentally change a row state then teh value of your function is automatically changed. If you want to set values based upon a current sate, use a formula then remove it, or use Set Each Value.
Hope that helps.
Names Default to Here(1);
dt = Open("$Sample_Data/Big Class.jmp");
//select 10 random rows in Big Class
xr = Random Shuffle( Index(1, nrow(dt)) ) [1::10];
dt << select rows(xr);
dt << Label(1);
dt << clear select;
biv = dt << Bivariate( Y( :weight ), X( :height ), Fit Line );
//---run to here ----
//Now you will see all the names since name is a label.
//Remove, Name as a Label
dt:name << set Labelled(0);
//---run to here ----
//now all the row numbers are visible If you use a formula for Labeled rows, when you
//remove row labeling, the formula will be updated all data will be Clean Bad Data,
//so use Set Each Value.
dt << New Column( "Outliers",
Character,
<<SET each="" value=""></SET>