CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Visualization & Post-Processing Software > ParaView

[OpenFOAM] Problem: Export one colum of spreadsheet

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By arvhult

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 19, 2013, 12:35
Default Problem: Export one colum of spreadsheet
  #1
New Member
 
Anonymous
Join Date: Mar 2012
Posts: 13
Rep Power: 14
LiteCFD is on a distinguished road
Hi all!

I have problem with paraview results export;

After data load i use Contour filter. It's required for drawing free surface.

Then i try to export only coordinates of contour point:
- select necessary column from spreadsheet
- File -> Save Data.

But in result csv there are all arrays (P, U, alpha, etc)

Please help. What I'm doing wrong? May be I also should use another filter?

BTW, can I copy columns directly from spreadsheet view? Ctrl+C of Edit->Copy don't work.

Thanks a lot!
LiteCFD is offline   Reply With Quote

Old   November 20, 2013, 02:58
Default
  #2
Senior Member
 
Tom Fahner
Join Date: Mar 2009
Location: Breda, Netherlands
Posts: 634
Rep Power: 32
tomf will become famous soon enoughtomf will become famous soon enough
Send a message via MSN to tomf Send a message via Skype™ to tomf
Hi,

Usually I use some shell commands to modify the content. Something like this should work:

Code:
sed 's/,/ /g' <filename>.csv | awk '{print $1}' > column1.csv
Use $2 in the awk print part for column 2 of the csv file or if you want only columns 1 and 3, use:

Code:
sed 's/,/ /g' <filename>.csv | awk '{print $1 "," $3}' > column1and3.csv
This is more a workaround though.

Regards,
Tom
tomf is offline   Reply With Quote

Old   November 20, 2013, 03:02
Default
  #3
Senior Member
 
Bernhard
Join Date: Sep 2009
Location: Delft
Posts: 790
Rep Power: 21
Bernhard is on a distinguished road
The pipe from sed to awk seems obsolete if you could use the IFS input for awk. Anyhow:
Code:
cut -d',' -f1 <filename>.csv
would do the job too

Last edited by wyldckat; November 20, 2013 at 17:12. Reason: Added [CODE][/CODE]
Bernhard is offline   Reply With Quote

Old   March 18, 2014, 09:19
Default
  #4
New Member
 
Carl-Magnus Arvhult
Join Date: Feb 2014
Posts: 12
Rep Power: 12
arvhult is on a distinguished road
Quote:
BTW, can I copy columns directly from spreadsheet view? Ctrl+C of Edit->Copy don't work.
I found that "file -> export scene" exports the actual selection in the spreadsheet view. It took way too much time to realize this...
This is ParaView 4.1.0 64-bit.

I share your opinion that a simple copy-paste functionality would be helpful!

Warm regards,
Carl-Magnus Arvhult
wyldckat likes this.
arvhult is offline   Reply With Quote

Old   March 21, 2014, 17:03
Default
  #5
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,975
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
@Carl-Magnus Arvhult: Many thanks for sharing your finding!

By the way, if anyone needs to do this in Python within ParaView: http://markmail.org/message/anlxxwlrlyacmsr6
wyldckat is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[OpenFOAM.org] Compiling OpenFOAM 5.0 on the Titan Supercomputer wildfire230 OpenFOAM Installation 20 May 6, 2020 07:30
[foam-extend.org] foam-extend-4.0 gcc errors & maybe paraFoam powerline332 OpenFOAM Installation 3 May 24, 2018 21:16
[General] Export spreadsheet from pvpython wgan ParaView 0 June 10, 2016 15:53
[Commercial meshers] Problem with export unstructured mesh in OpenFOAM AdrianoCT OpenFOAM Meshing & Mesh Conversion 2 June 24, 2015 03:56
CFX results export problem ? nasir CFX 2 November 4, 2011 21:10


All times are GMT -4. The time now is 23:01.