[Paraview] Export output from "plot over line" filter in a text file

Jul D juliolatengo at gmail.com
Wed Jun 13 12:13:40 EDT 2007


That is exactly what I was looking for!
Thank you very much.

Julien

2007/6/13, Olivier Ricou <olivier at ricou.eu.org>:
>
> die 13/06/07, ad 12h13, Jul D <juliolatengo at gmail.com> dixit :
> > Hello all,
> >
> > I'm currently using Paraview 3.0.0 to visualize Ensight data. I am able
> to
> > plot a 1D graph with the "plot over line" filter. I would like to
> process
> > those results but unlike in Paraview 2.x, it is here not possible to
> export
> > the data in a *.csv file. Do you think a Python script would do this? I
> > found very few documentation on Python scripting in Paraview.
>
> do you plot with ProbeLine then with that element activated, choose
> Programmable Filter and put this script :
>
> print "------------------"
> pdi = self.GetInput()
> nbp = pdi.GetNumberOfPoints()
> vals = pdi.GetPointData().GetScalars("p")
> for i in range(0,nbp):
>   print "%d : %e" % (i,vals.GetValue(i))
> print "------ done ----------"
>
> of course you have to print in the csv format and to choose your variable
> (instead of "p").
>
> Olivier.
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.3 (GNU/Linux)
>
> iD8DBQFGb9feXwl5UewLtBARApgsAJ4pt5vNXPM73TChu0MhfzvC3YMtsQCeNOb8
> HkuWtAmNwUsxUZaPT1r02ag=
> =YWUv
> -----END PGP SIGNATURE-----
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/paraview/attachments/20070613/503b76c4/attachment.htm


More information about the ParaView mailing list