cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • JMP 19 is here! See the new features at jmp.com/new.
  • Due to global connectivity issues impacting AWS Services, users may experience unexpected errors while attempting to authorize JMP. Please try again later or contact support@jmp.com to be notified once all issues are resolved.

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