cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
The Discovery Summit 2025 Call for Content is open! Submit an abstract today to present at our premier analytics conference.
%3CLINGO-SUB%20id%3D%22lingo-sub-623313%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3ERe%3A%20JSL%20statement%20to%20turn%20off%20and%20turn%20on%20Upper%20and%20Lower%20Limits%20in%20Control%20Chart%20Builder%20from%20a%20Make%20Column%20Switch%20Handler%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-623313%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%3CP%3EDo%20you%20mean%20these%20checkboxes%3F%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22jthi_0-1681804259202.png%22%20style%3D%22width%3A%20182px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Fcommunity.jmp.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F52052i059079BB5220A29F%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22jthi_0-1681804259202.png%22%20alt%3D%22jthi_0-1681804259202.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EI%20think%20you%20might%20have%20to%20go%20with%20manipulating%20the%20checkboxboxes%20directly.%20Below%20is%20fairly%20quick%20made%20one%2C%20can%20be%20made%20much%20better%3C%2FP%3E%0A%3CPRE%3E%3CCODE%20class%3D%22%20language-jsl%22%3ENames%20Default%20To%20Here(1)%3B%0Adt%20%3D%20Open(%22%24SAMPLE_DATA%2FQuality%20Control%2FCoating.jmp%22)%3B%0Aobj%20%3D%20dt%20%26lt%3B%26lt%3B%20Control%20Chart%20Builder(Variables(Y(%3AWeight)%2C%20Subgroup(%3ASample)))%3B%0A%0Aget_cbs%20%3D%20Expr(%0A%20tbs%20%3D%20Report(obj)%20%26lt%3B%26lt%3B%20XPath(%22%2F%2FTextBox%5Bcontains(text()%2C%20'Show%20Lower%20Limit')%20or%20contains(text()%2C%20'Show%20Upper')%20or%20contains(text()%2C%20'Show%20Center%20Line')%5D%22)%3B%0A%20mbs%20%3D%20tbs%20%26lt%3B%26lt%3B%20parent%3B%0A%20cbs%20%3D%20mbs%20%26lt%3B%26lt%3B%20sib%3B%0A)%3B%0A%0Aget_cbs%3B%0A%0AFor(i%20%3D%201%2C%20i%20%26lt%3B%3D%20N%20Items(cbs)%2C%20i%2B%2B%2C%0A%20get_cbs%3B%0A%20cbs%5Bi%5D%20%26lt%3B%26lt%3B%20Set(1%2C0)%3B%0A)%3B%0A%3C%2FCODE%3E%3C%2FPRE%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-623553%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3ERe%3A%20JSL%20statement%20to%20turn%20off%20and%20turn%20on%20Upper%20and%20Lower%20Limits%20in%20Control%20Chart%20Builder%20from%20a%20Make%20Column%20Switch%20Handler%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-623553%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%3CP%3EJarmo%2C%3C%2FP%3E%0A%3CP%3EThis%20is%20exactly%20what%20I%20need.%3C%2FP%3E%0A%3CP%3EThanks%3C%2FP%3E%0A%3CP%3EJim%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-623200%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3EJSL%20statement%20to%20turn%20off%20and%20turn%20on%20Upper%20and%20Lower%20Limits%20in%20Control%20Chart%20Builder%20from%20a%20Make%20Column%20Switch%20Handler%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-623200%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%3CP%3EI%20am%20working%20on%20a%20Community%20Discussion%20entry.%26nbsp%3B%20My%20proposed%20solution%20uses%20a%20Make%20Column%20Switch%20Handler%20to%20change%20the%20Control%20Chart%20Builder%20display%20from%20a%20standard%20XBar%20chart%20with%20read%20in%20Control%20Limits%2C%20when%20they%20are%20available%2C%20to%20a%20Run%20chart%20with%20no%20limits.%26nbsp%3B%20The%20issue%20is%20specifically%20with%20the%20turning%20on%20and%20off%20of%20the%20displaying%20of%20the%20control%20limits.%26nbsp%3B%20The%20functionality%20exists%20on%20the%20Control%20Panel%2C%20but%20I%20have%20not%20been%20able%20to%20find%20a%20method%20to%20change%20the%20display%2Fno%20display%20programmatically%20after%20the%20chart%20has%20been%20displayed.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAnyone%20have%20experience%20with%20this%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-623200%22%20slang%3D%22en-US%22%20mode%3D%22NONE%22%3E%3CLINGO-LABEL%3EData%20Exploration%20and%20Visualization%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EQuality%20and%20Process%20Engineering%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Choose Language Hide Translation Bar
txnelson
Super User

JSL statement to turn off and turn on Upper and Lower Limits in Control Chart Builder from a Make Column Switch Handler

I am working on a Community Discussion entry.  My proposed solution uses a Make Column Switch Handler to change the Control Chart Builder display from a standard XBar chart with read in Control Limits, when they are available, to a Run chart with no limits.  The issue is specifically with the turning on and off of the displaying of the control limits.  The functionality exists on the Control Panel, but I have not been able to find a method to change the display/no display programmatically after the chart has been displayed.

 

Anyone have experience with this?

Jim
1 ACCEPTED SOLUTION

Accepted Solutions
jthi
Super User

Re: JSL statement to turn off and turn on Upper and Lower Limits in Control Chart Builder from a Make Column Switch Handler

Do you mean these checkboxes? 

jthi_0-1681804259202.png

 

I think you might have to go with manipulating the checkboxboxes directly. Below is fairly quick made one, can be made much better

Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Quality Control/Coating.jmp");
obj = dt << Control Chart Builder(Variables(Y(:Weight), Subgroup(:Sample)));

get_cbs = Expr(
	tbs = Report(obj) << XPath("//TextBox[contains(text(), 'Show Lower Limit') or contains(text(), 'Show Upper') or contains(text(), 'Show Center Line')]");
	mbs = tbs << parent;
	cbs = mbs << sib;
);

get_cbs;

For(i = 1, i <= N Items(cbs), i++,
	get_cbs;
	cbs[i] << Set(1,0);
);
-Jarmo

View solution in original post

2 REPLIES 2
jthi
Super User

Re: JSL statement to turn off and turn on Upper and Lower Limits in Control Chart Builder from a Make Column Switch Handler

Do you mean these checkboxes? 

jthi_0-1681804259202.png

 

I think you might have to go with manipulating the checkboxboxes directly. Below is fairly quick made one, can be made much better

Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Quality Control/Coating.jmp");
obj = dt << Control Chart Builder(Variables(Y(:Weight), Subgroup(:Sample)));

get_cbs = Expr(
	tbs = Report(obj) << XPath("//TextBox[contains(text(), 'Show Lower Limit') or contains(text(), 'Show Upper') or contains(text(), 'Show Center Line')]");
	mbs = tbs << parent;
	cbs = mbs << sib;
);

get_cbs;

For(i = 1, i <= N Items(cbs), i++,
	get_cbs;
	cbs[i] << Set(1,0);
);
-Jarmo
txnelson
Super User

Re: JSL statement to turn off and turn on Upper and Lower Limits in Control Chart Builder from a Make Column Switch Handler

Jarmo,

This is exactly what I need.

Thanks

Jim

Jim