cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Choose Language Hide Translation Bar
Elise_B
Level III

Script de capabilité

Bonjour,

Je veux faire un script de capabilité en laissant l'utilisateur choisir sur quel paramètre il souhaite réaliser l'analyse de capabilité. 

J'ai une combo box qui propose tous les paramètres possibles et je récupère le choix de l'utilisateur dans la variable choixCapa. L'utilisateur doit aussi rentrer à la main les valeurs des limites inférieures et supérieures et de l'objectif. 

Text Box("Veuillez choisir un paramètre :"),
comboCapa = Combo Box (columns_table_ref, choixCapa = comboCapa << Get Selected),
Text Box("Veuillez renseigner les paramètres suivants :"),
Text Box("Limite inférieure :"),
lim_inf_neb = Number Edit Box(),
Text Box("Objectif :"),
obj_neb = Number Edit Box(),
Text Box("Limite supérieure :"),
lim_sup_neb = Number Edit Box(),
okCapa = Button Box ("Valider", capacite)

Ensuite, j'ai un script qui trace la capabilité :

capacite = expr(
	lim_inf = lim_inf_neb << get;
	lim_sup = lim_sup_neb << get;
	obj = obj_neb << get;
	Process Capability(
		Process Variables(As Column(choixCapa) ),
		Spec Limits( As Column(choixCapa)( LSL( lim_inf ), Target( obj ), USL( lim_sup ) ) ),
		Moving Range Method( Average of Moving Ranges ),
		Individual Detail Reports( 1 ),
		Capability Box Plots( 0 ),
		Goal Plot( 0, Capability Lines( 1.0217 ), Show Overall Sigma Points( 0 ) ),
		Capability Index Plot( 0 ),
		Process Performance Plot( 0 ),
		SendToReport(
			Dispatch(
				{"Individual Detail Reports", choixCapa||" Capability", "Histogram"},
				"Process Capability Analysis Histogram",
				FrameBox,
				{Frame Size( 311, 19 )}
			),
			Dispatch(
				{"Individual Detail Reports", choixCapa||" Capability", "Histogram"},
				"Process Capability Analysis Histogram",
				FrameBox( 2 ),
				{Frame Size( 311, 160 )}
			)
		)
	)
);

J'ai une erreur au niveau de la ligne Process Variables où je spécifie le nom de colonne qui est l'input de l'utilisateur :

La colonne spécifiée est introuvable dans la table de données. lors de l'accès ou de l'évaluation de « List » , {/*###*/choixCapa}

 

Je ne sais pas comment faire pour transformer mon input en nom de colonne compréhensible pour tracer la capabilité ...

 

Merci d'avance pour vos réponses

Elise B.
1 ACCEPTED SOLUTION

Accepted Solutions
jthi
Super User

Re: Script de capabilité

Try if using Eval() instead of AsColumn() helps.

 

If not then you might have to resort into something like Insert one expression into another using Eval Insert, Eval Expr, Parse, and Substitute 

-Jarmo

View solution in original post

1 REPLY 1
jthi
Super User

Re: Script de capabilité

Try if using Eval() instead of AsColumn() helps.

 

If not then you might have to resort into something like Insert one expression into another using Eval Insert, Eval Expr, Parse, and Substitute 

-Jarmo