Our World Statistics Day conversations have been a great reminder of how much statistics can inform our lives. Do you have an example of how statistics has made a difference in your life? Share your story with the Community!
Choose Language Hide Translation Bar
Highlighted
natalie_
Level V

Range Check on Derived Columns

Hi everyone,

 

I have copied/duplicated columns in my data table.  I would like to do a range check on the copied columns, but when I do, it tells me that I can not do a range check on derived columns.  The easiest work around (I think) would be to just do the range check on the original column, but I would like to know if there is a way to do this on the copied column.

 

Current Data Table(dt);
cn = dt << get column names();
For(i=5, i <= N Items(cn), i++,
name = Char((cn[i])) || " Pass";
dt << clear column selections;
colCopy = cn[i] << getscript;
Eval(Substitute(Name Expr(colCopy), Arg(Name Expr(colCopy),1), name )) << set selected(1);
col = Column(name);
dt:col << Suppress Eval;
);



dt:Gate Pass << Set Property("Range Check", LTLE(0,50) );

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
natalie_
Level V

Re: Range Check on Derived Columns

The problem was so obvious!  I didn't set the data type to numeric.  Ah!

View solution in original post

7 REPLIES 7
Highlighted
Phil_Brown
Super User

Re: Range Check on Derived Columns

Not able to reproduce your issue. I am using JMP 12/13. I am able to apply a range check to the new columns as you explained. Now, if a column is based on a formula, then no, you cannot apply Range Check. What version of JMP are you using?

PDB
Highlighted
natalie_
Level V

Re: Range Check on Derived Columns

Oh really? I am using JMP 12.
Highlighted
natalie_
Level V

Re: Range Check on Derived Columns

Oh actually it's happening on columns that weren't even copied.  Has anyone seen this problem before?

Highlighted
Phil_Brown
Super User

Re: Range Check on Derived Columns

Is the code you posted exactly what you're using? If not please post anything that's missing

PDB
Highlighted
natalie_
Level V

Re: Range Check on Derived Columns

The problem was so obvious!  I didn't set the data type to numeric.  Ah!

View solution in original post

Highlighted
Phil_Brown
Super User

Re: Range Check on Derived Columns

That certainly explains it! Glad you figured it out.

PDB
Highlighted

Re: Range Check on Derived Columns

A column populated by a formula would include the range checking in the formula itself. For example,

If( lower bound < computation < upper bound, result, . )
Learn it once, use it forever!
Article Labels

    There are no labels assigned to this post.