<div dir="ltr">Hi Richard,<div><br></div><div>You won't be able to set a vtkDataArray subclass as the input to a PlotOverLine filter. Instead, you should read the log files in a Programmable Source, and connect the Programmable Source to the PlotOverLine filter.</div><div><br></div><div>See Chapter 13 of the ParaView Guide [1].</div><div><br></div><div>Hope that helps,</div><div>Cory</div><div><br></div><div>[1] <a href="http://www.paraview.org/paraview-downloads/download.php?submit=Download&version=v4.3&type=data&os=all&downloadFile=TheParaViewGuide-v4.3-CC-Edition.pdf">http://www.paraview.org/paraview-downloads/download.php?submit=Download&version=v4.3&type=data&os=all&downloadFile=TheParaViewGuide-v4.3-CC-Edition.pdf</a></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Sep 8, 2015 at 3:57 AM, no name <span dir="ltr"><<a href="mailto:keinepostnurmuell@gmail.com" target="_blank">keinepostnurmuell@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hey there<div><br></div><div>I have some hundred VTU files and I want to plot some data in a graph (Plot over Line - POL) next to it. The Problem is, the data from these POLs is coming from a simple log file, basically conaining only x and y values (like two np.arrays).</div><div><br></div><div>I can transform the arrays via </div><div><br></div><div><pre style="margin-top:0px;padding:5px;border:0px;font-size:13px;overflow:auto;width:auto;max-height:600px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,sans-serif;color:rgb(57,51,24);word-wrap:normal;background-color:rgb(238,238,238)"><code style="margin:0px;padding:0px;border:0px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,sans-serif;white-space:inherit"><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,139)">from</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> vtk</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">.</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">util </span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,139)">import</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> numpy_support 
values </span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">=</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> np</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">.</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">array</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">((</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">x</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">,</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">y</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">))</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">
vtk_values </span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">=</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> numpy_support</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">.</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">numpy_to_vtk</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">values</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">,</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> array_type</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">=</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">vtk</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">.</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">VTK_FLOAT</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">)</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">
vtk_values</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">.</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">setName</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">'values_2_show'</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">)</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">
vtk_values</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">.</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">setComponentName</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">1</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">,</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> </span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">'x_value'</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">)</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">
vtk_values</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">.</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">setComponentName</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">2</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">,</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> </span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">'y_value'</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">)</span></code></pre></div><div>But so far I have no success with how to change the input (source)</div><div><pre style="margin-top:0px;padding:5px;border:0px;font-size:13px;overflow:auto;width:auto;max-height:600px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,sans-serif;color:rgb(57,51,24);word-wrap:normal;background-color:rgb(238,238,238)"><code style="margin:0px;padding:0px;border:0px;font-family:Consolas,Menlo,Monaco,'Lucida Console','Liberation Mono','DejaVu Sans Mono','Bitstream Vera Sans Mono','Courier New',monospace,sans-serif;white-space:inherit"><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">VTUFILE </span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">=</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> </span><span style="margin:0px;padding:0px;border:0px;color:rgb(43,145,175)">FindSource</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">'VTUFILE*'</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">)</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">
plotOverLine1 </span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">=</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> </span><span style="margin:0px;padding:0px;border:0px;color:rgb(43,145,175)">PlotOverLine</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">(</span><span style="margin:0px;padding:0px;border:0px;color:rgb(43,145,175)">Input</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">=</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">VTUFILE</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">,</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)"> </span><span style="margin:0px;padding:0px;border:0px;color:rgb(43,145,175)">Source</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">=</span><span style="margin:0px;padding:0px;border:0px;color:rgb(128,0,0)">'High Resolution Line Source'</span><span style="margin:0px;padding:0px;border:0px;color:rgb(0,0,0)">)</span></code></pre></div><div>to a simple array.</div><div><br></div><div>Thanks for any help!</div><div>Richard</div></div>
<br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the ParaView Wiki at: <a href="http://paraview.org/Wiki/ParaView" rel="noreferrer" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=ParaView" rel="noreferrer" target="_blank">http://markmail.org/search/?q=ParaView</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/paraview" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/paraview</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">Cory Quammen<br>R&D Engineer<br>Kitware, Inc.</div>
</div>