Jump to content

read only certain columns from an asci file


Recommended Posts

Hi

I have a file with an header (the column names) and data

fields and data are delimited by space

example

date size amount lenght number

1/1/2009 20 2000 12 3

..

..

other 100 rows with similar data

....

2/3/2009 10 4000 1 333

i would like to read only the data that "belongs" to the fields amount and number

keep in mind that order an number of fields in the header can change

example of other header

size number length other1 other2 other3 other4 other5 amount other6 other7.......

any suggestion ?

thanks

(i need something like get data by column name)

Link to comment

This should be what you need.....

post-9410-125128318099_thumb.png

Hi

I have a file with an header (the column names) and data

fields and data are delimited by space

example

date size amount lenght number

1/1/2009 20 2000 12 3

..

..

other 100 rows with similar data

....

2/3/2009 10 4000 1 333

i would like to read only the data that "belongs" to the fields amount and number

keep in mind that order an number of fields in the header can change

example of other header

size number length other1 other2 other3 other4 other5 amount other6 other7.......

any suggestion ?

thanks

(i need something like get data by column name)

Link to comment

It is just the Index Array in the Array Sub-Palette

post-9410-12512941993_thumb.png

[from the LabVIEW Help]

When you wire an array to this function, the function resizes automatically to display index inputs for each dimension in the array you wire to n-dimension array. You also can add additional element or subarray terminals by resizing the function. The connector pane displays the default data types for this polymorphic function.

[/from the LabVIEW Help]

In this case when you wire up the 2D string array to the array input it resizes to provide a row and col index.

Just wire up the col index (leaving the row index unwired) to get the complete column.

i am afraid i can't find this function. i'm using labview 8.5. what are its features ? what is its name ?

thanks

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.