cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Don’t miss your chance to experience Discovery Summit Europe at our best available rate! Early bird registration through 31 Oct.
  • Graph Builder Toolbar streamlines interactive graphing. Creates shortcuts on Report and GraphBuilder Helpers toolbars. Download and install the extension.
  • JMP will suspend normal business operations for our Rest and Recharge Day on Friday, October 2, 2026.
    Regular business hours will resume on Monday, October 5, 2026.

Discussions

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

Fonction Loc

Bonjour à tous,

 

Dans une table de données, j'ai deux colonnes : Numéro & Code

En utilisant la fonction "Loc" je cherche des indices dans la table de données.

 

Names default to here(1);

dt = current data table();

VALEUR = Loc( dt[Row(), "Numéro"], 1);
// VALEUR1 = Loc( dt[Row(), "Numéro"], 1) & Loc( dt[Row(), "Code"], "A") ;

Comment peut-on appliquer la fonction "Loc" avec une double condition (j'ai essayé avec "AND").

 

Merci pour votre réponse.

2 ACCEPTED SOLUTIONS

Accepted Solutions
txnelson
Super User

Re: Fonction Loc

I suggest using "Get Rows Where"

Names default to here(1);

dt = current data table();

VALEUR = dt << get rows where( :Numéro == 1 & :Code == "A" );
Jim

View solution in original post

jthi
Super User

Re: Fonction Loc

And if you have JMP18 you can use new Where()

And if you have JMP18, new Where()

Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Big Class.jmp");
rs = Where(dt, :sex == "F" & :age == 12);


-Jarmo

View solution in original post

2 REPLIES 2
txnelson
Super User

Re: Fonction Loc

I suggest using "Get Rows Where"

Names default to here(1);

dt = current data table();

VALEUR = dt << get rows where( :Numéro == 1 & :Code == "A" );
Jim
jthi
Super User

Re: Fonction Loc

And if you have JMP18 you can use new Where()

And if you have JMP18, new Where()

Names Default To Here(1);
dt = Open("$SAMPLE_DATA/Big Class.jmp");
rs = Where(dt, :sex == "F" & :age == 12);


-Jarmo

Recommended Articles