Subscribe Bookmark RSS Feed

How to export JMP result to a Microsoft office file such as excel?

664786828

Community Trekker

Joined:

Jul 2, 2015

        I am a tester engineer, and I use JMP soft a few months.As a test engineer, one thing i need to do is export test report !

Every day I need to do some repetitive work , for example , every time i will use 'Graph Builder' to draw  wafer mapping ,copy the JMP results and then paste them to Excel. Because i have almost ten Values to be showed on mapping, i spend so much on it .I always need to copy /paste copy/ paste etc. It is so boring.

      So  i need your help . Can you give some advice on how to export JMP result to excel  by JSL instead of  Copying &Pasting!    

       

9174_2015-03-20_230301.png

Graph Builder

4 REPLIES
ian_jmp

Staff

Joined:

Jun 23, 2011

Once you have a report window from a JMP platform, you can save it in a variety of formats. For example (adding a line to some code I posted earlier), you can save a picture to the desktop:

NamesDefaultToHere(1);

dt = NewTable("Map",

  NewColumn("x", Numeric, Continuous, Formula(RandomInteger(1, 20))),

  NewColumn("y", Numeric, Continuous, Formula(RandomInteger(1, 20))),

  NewColumn("Label 1", Numeric, Continuous, Formula(RandomInteger(1, 5))),

  NewColumn("Label 2", Numeric, Continuous, Formula(RandomInteger(1, 5))),

  AddRows(100)

  );

Column(dt, "Label 1") << Label;

Column(dt, "Label 2") << Label;

// (1) Mouse over some points to see the tooltip.

// (2) Move to the right of the tip to make it persist using the red pin.

// (3) Right click on the tip to see how you can change its properties (colours, tag line etc.).

// (4) Save the Graph Builder script to see how to do this in JSL if you need to

gb = dt << Graph Builder(

  Size( 530, 454 ),

  Show Control Panel( 0 ),

  Variables( X( :x ), Y( :y ) ),

  Elements( Points( X, Y, Legend( 5 ) ) ),

);

// Save a picture of the report to the desktop

Report(gb) << savePicture("$DESKTOP/SquareWafer.png", PNG);

But the precise answer to your question 'how to export JMP result to excel' depends on what format you want, and how you want Excel to consume it. If you want a fully automated solution, check out the 'automation' capabilities of JMP ('Help > Books > Scripting Guide', then search for 'OLE automation').

664786828

Community Trekker

Joined:

Jul 2, 2015

Thanks for your answer. I want to talk about it based on your answer.

gb = dt << Graph Builder(

  Size( 530, 454 ),

  Show Control Panel( 0 ),

  Variables( X( :x ), Y( :y ) ),

  Elements( Points( X, Y, Legend( 5 ) ) ),

);

// Save a picture of the report to the desktop

Report(gb) << savePicture("$DESKTOP/SquareWafer.png", PNG);

// here we get a picture from JMP, then i need to insert these pic to a existed excel file.

can i immediately save the pic results to the file i want.

ian_jmp

Staff

Joined:

Jun 23, 2011

OK, so if you are happy with just images, you can easily write a script to construct your test report, and dump each relevant picture to a folder of your choice, and do this part automatically.

But then, you have to get these into Excel, and I'm not quailed to give any advice as to the best way to do this. I imagine, though, that a Visual Basic script could do it easily. If you Google 'insert image in Excel' you should get some ideas, and it seems there are free Excel add-ins designed for this purpose.

This would not be truly automated in the sense of OLE, but it would be a lot better than what you do now . . .

hlrauch

Community Trekker

Joined:

Sep 19, 2014

I'd like to build on Ian's answer. If you have a script that creates the output and then saves the desired output as an image file (.png), you can use a trick in Excel (no OLE needed). In Excel (I'm running Excel 2010) select Insert on the ribbon menu bar and then select Picture. Select your saved image file and then click on the triangle next to the Insert button and select "Insert and Link." Now, whenever the Excel file is opened, Excel will automatically link to the latest version of the image file at that location. You will only need to run the script that creates the image file; Excel will take care of the rest..

I'm not an Excel expert, so please correct me if I missed anything.

Howard