Get Help

Turn on suggestions

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

Showing results for

- Community
- :
- PTC Mathcad
- :
- PTC Mathcad
- :
- Large Tables - Mathcad Prime 2.0

Options

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

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

Showing results for

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
11:30 AM

11-21-2013
11:30 AM

Is there a way to split large tabels in MCPrime 2.0? I have a table with roughly 100+ data points for 2 variables that i need to reference from and having it all in a straight table it would take up two pages and look horrible. It would look a lot better if i could split the table into 3 sections and put it on one page.

EDIT:

To Clarify i have an imperical table that has a corection factor for a given temperature. It has 100+ data points. The temperature is calculated earlier in the document so i want the table put out the corection factor which i will use in further calculations

Solved! Go to Solution.

Labels:

1 ACCEPTED SOLUTION

Accepted Solutions

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
12:54 PM

11-21-2013
12:54 PM

I am not sure from your explanation what the goal of the splitting is.

Are you talking about the new table structure which was newly introduced with Prime where you can only type in the values manually or is the table you are talking of a normal matrix which is either calculated or read in (or also manually typed)?

Matrices can be resized so they do not show all the values and can be scrolled (in a very strange an cumbersome way), so the will not take up that much space.

As you write that you just want to hide the tables from view you may consider putting the table in a collapsible area and closing it.

I am absolutely unsure what you want to do with a programming if statement. I think you will have to clarify and better attach your sheet to show what you are trying to do.

EDIT: Can it be that you are looking for something like the lookup() functions to lookup a given temperature in your table and return the appropriate correction factor? You may lookup lookup() (pun intended ) in the help or online here: http://www.ptc.com/cs/help/mathcad_hc/prime2_hc/mprime_en/mprime/lookup_functions.html

10 REPLIES 10

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
12:21 PM

11-21-2013
12:21 PM

Re: Large Tables - Mathcad Prime 2.0

When you say "split" a table, I assume you want to do it mainly for display purposes?

To view portions of large matrices, click on the '...' portion, which then brings up the matrix navigator. You can then scroll up/down and/or left/right.

I suppose you could also use the 'submatrix' function to split up the matrix and show them side by side.

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
12:36 PM

11-21-2013
12:36 PM

Re: Large Tables - Mathcad Prime 2.0

I tried just hiding the table but all the answers tied to that variable show about 10 possiblities and then "...." Looks like i'm going to have to use some sort of if then statement.

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
12:54 PM

11-21-2013
12:54 PM

I am not sure from your explanation what the goal of the splitting is.

Are you talking about the new table structure which was newly introduced with Prime where you can only type in the values manually or is the table you are talking of a normal matrix which is either calculated or read in (or also manually typed)?

Matrices can be resized so they do not show all the values and can be scrolled (in a very strange an cumbersome way), so the will not take up that much space.

As you write that you just want to hide the tables from view you may consider putting the table in a collapsible area and closing it.

I am absolutely unsure what you want to do with a programming if statement. I think you will have to clarify and better attach your sheet to show what you are trying to do.

EDIT: Can it be that you are looking for something like the lookup() functions to lookup a given temperature in your table and return the appropriate correction factor? You may lookup lookup() (pun intended ) in the help or online here: http://www.ptc.com/cs/help/mathcad_hc/prime2_hc/mprime_en/mprime/lookup_functions.html

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
05:10 PM

11-21-2013
05:10 PM

Re: Large Tables - Mathcad Prime 2.0

I'm getting my answer as [#]. i guess because its returning a 1x1 matrix answer. is there a function that will turn that into a regular number. For presentations sake?

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
05:14 PM

11-21-2013
05:14 PM

Re: Large Tables - Mathcad Prime 2.0

nevermind, found an operator that returned the normal of the matrix

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
06:01 PM

11-21-2013
06:01 PM

Re: Large Tables - Mathcad Prime 2.0

So you found the vector index ([0).

lookup() has to return a vector of values as it might be that the searched for value is present more than once. It will do so for consistency as you already guessed also if only one occurence is found.

using lookup(....)[0 will return the value of the first one found.

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
01:08 PM

11-21-2013
01:08 PM

Re: Large Tables - Mathcad Prime 2.0

This is a common problem with large data sets. I had a data set that was hundreds of pages. I would recommend showing the first 10 or so lines and provide the complete data set in a seperate document, text file, excel spreadsheet, etc. I prefer excel, because I can label the columns. This has the added benefit of changing the data without changing the logic in your analysis. Takes some preplanning and practice.

Good luck

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
03:33 PM

11-21-2013
03:33 PM

Re: Large Tables - Mathcad Prime 2.0

So if the goal is arranging the (two column, I guess) data for presentation, a small Mathcad program could be written to rearrange the data in a multi column matrix. Rudimentary labels would also be possible (text fields) but an Excel sheet sure would look prettier.

But then as I understood Bryan he does not want to show the data but rather wants to hide it from view. But then, I may be wrong.

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
04:43 PM

11-21-2013
04:43 PM

Re: Large Tables - Mathcad Prime 2.0

Thank you all, i think the lookup() function is what i need. I need the lookup functionality but i would have liked to shown the table i was using for reference sake. In the document currently is an image file of the table and that was serving as a manual look up. I was hoping to add a bit of functionality so there would be one less step for the person inputting the data. Thank you all.

P.S. By splitting the table i meant something like below:

x y x y x y

1 16 31

2 17 32

3 18 33

4 19 34

5 20 35

. . .

. . .

. . .

where as right now all i can get is

x y

1

2

3

4

5

6

7

.

.

.

as you can see the first table would present much better especially if as a single column it would go for several pages.

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

11-21-2013
05:57 PM

11-21-2013
05:57 PM

Re: Large Tables - Mathcad Prime 2.0

So you might find the attached splitTable routine useful.

Furthermore, depending on your application and the data you have, a interpolating function might be useful instead of using lookup().