Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- JMP User Community
- :
- Discussions
- :
- Discussions
- :
- changing the format of the column in JSL

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Aug 31, 2012 11:23 AM
(15176 views)

i have an excel sheet with 5 columns and one of the column "Number" has a format of Data type(Character) and Modeling Type (Nomial). I wrote a script in JSL to perform a row operation. I need to change the format of the column "Number" as soon as I open the file in JMP. I want the required format to be Data Type(Numeric) and Modeling TYpe(Continous). I wrote a script like this:

```
dt=open();
current data table<<set name("Data Sheet");
dt=data table("Data Sheet");
dt<< column("Number",Numeric,Continous,Format(Best,12) );
```

and the script goes on...

but it is not changing the format of the column. could someone help me with the script.?

2 ACCEPTED SOLUTIONS

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Here is one way to do it:

```
dt:Number << Data type( Numeric ) << Set Modeling Type( Continuous );
```

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

This is another way to do the same thing. Perhaps the syntax change will resolve the issue.

`column(dt,"Number")<<data type(Numeric)<<Modeling Type(Continuous)<<Format(Best,12);`

4 REPLIES 4

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Here is one way to do it:

```
dt:Number << Data type( Numeric ) << Set Modeling Type( Continuous );
```

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: changing the format of the column in JSL

Can you please tell the exact format for the script that you wrote?

I used the same line:

```
dt=open();
dt:Number << Data type( Numeric ) << Set Modeling Type( Continuous );
```

so that once I open the required sheet, The format of the column "Number" is changed to Numeric and Continous, but unfortunately it is not working.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

This is another way to do the same thing. Perhaps the syntax change will resolve the issue.

`column(dt,"Number")<<data type(Numeric)<<Modeling Type(Continuous)<<Format(Best,12);`

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

Re: changing the format of the column in JSL

Hi FR2007,

The answer of MS is rigth.

But if you would like to prevent this problem, you have to format the variable as Numeric in the Excel file. Then JMP will understand the format of the column fine.

Also you have to avoid any character string in this column in the Excel file (except the row of column names), including cells with a space only (replace it for nothing).

Teresa