[Paraview] vtkTable and LineChart

Marcus D. Hanwell marcus.hanwell at kitware.com
Mon Nov 29 16:31:52 EST 2010


Sorry, yes, I was in VTK world. There are a few column names with
special meanings to ParaView that are hard coded in the proxy. You can
get at the chart object if you wish to manipulate it directly, but you
should be able to achieve everything you need to through the proxies.

Marcus

On Mon, Nov 29, 2010 at 4:28 PM, pat marion <pat.marion at kitware.com> wrote:
> I think by default it will plot a line for each column in the table.  It
> will use the cell value as the Y value, and the row index as the X value.
> To change the behavior, you have to change two representation properties:
>
>
> rep.UseIndexForXAxis = 0
>
> rep.XArrayName = 'foo'
>
> This will plot all all the columns, except use the "foo" column as the X
> values.  That means the line for the "foo" column is still displayed, and it
> will be a diagonal line.
>
> I just looked, and Paraview has one cheat hard coded- if there is a column
> named "Time" or "arc_length" then it will be used automatically for the X
> axis.
>
> Pat
>
> On Mon, Nov 29, 2010 at 4:11 PM, Michael Jackson
> <mike.jackson at bluequartz.net> wrote:
>>
>> Thanks for the idea. I was trying to figure out the flow from reading the
>> data into displaying the data hoping to reveal some sort of default or
>> something. I was going to generate some fake CSV data and see how that
>> reader does things hoping the CSV reader takes the first column as the
>> x-axis.
>> ___________________________________________________________
>> Mike Jackson                      www.bluequartz.net
>> Principal Software Engineer       mike.jackson at bluequartz.net
>> BlueQuartz Software               Dayton, Ohio
>>
>>
>>
>> On Nov 29, 2010, at 4:08 PM, pat marion wrote:
>>
>>> Hi Mike,
>>>
>>> I'm not up to speed with the current chart api so I can't answer your
>>> question... but maybe you could try doing it in the gui with python trace
>>> enabled, then translate the generated python code into c++ for your plugin?
>>>  Customizing the chart should be a matter of setting properties on the
>>> representation and view, the data object itself doesn't have much say.
>>>
>>> Pat
>>>
>>> On Mon, Nov 29, 2010 at 1:41 PM, Michael Jackson
>>> <mike.jackson at bluequartz.net> wrote:
>>> I have some XY data that I would like to plot in ParaView. I currently
>>> have a plugin that reads the data from our HDF5 file and into vtkTable
>>> objects. Along the lines of a "Line Chart 101" question how do I
>>> programmatically set the x-axis and y-axis columns?
>>>
>>> Thanks
>>> ___________________________________________________________
>>> Mike Jackson                      www.bluequartz.net
>>> Principal Software Engineer       mike.jackson at bluequartz.net
>>> BlueQuartz Software               Dayton, Ohio
>>>
>>>
>>>
>>> _______________________________________________
>>> Powered by www.kitware.com
>>>
>>> Visit other Kitware open-source projects at
>>> http://www.kitware.com/opensource/opensource.html
>>>
>>> Please keep messages on-topic and check the ParaView Wiki at:
>>> http://paraview.org/Wiki/ParaView
>>>
>>> Follow this link to subscribe/unsubscribe:
>>> http://www.paraview.org/mailman/listinfo/paraview
>>>
>>
>> _______________________________________________
>> Powered by www.kitware.com
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Please keep messages on-topic and check the ParaView Wiki at:
>> http://paraview.org/Wiki/ParaView
>>
>> Follow this link to subscribe/unsubscribe:
>> http://www.paraview.org/mailman/listinfo/paraview
>
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the ParaView Wiki at:
> http://paraview.org/Wiki/ParaView
>
> Follow this link to subscribe/unsubscribe:
> http://www.paraview.org/mailman/listinfo/paraview
>
>


More information about the ParaView mailing list