Hi, Raksha,

You’ve run into a wart in the Gnupot API.  By default, the line type increments 
with each curve plotted — even if the “curve” is an image.  So your overplotted 
vectors are being rendered with linetype 2, which is both a different color and 
also dashed.  You can avoid that by explicitly using the curve option “lt=>1” 
(“linetype 1”) on the second plot.  Just throw “lt=>1” into the parameter list 
right after the “with” option.

You can also suppress dashes with “dt=>1” (“dashtype 1”) as a curve option.



> On May 30, 2018, at 10:18 AM, Raksha Singla <[email protected]> wrote:
> 
> Hi,
> 
> 
> I am new to Perl and PDL and I tried to use PDL::Graphics::Gnuplot 
> package in my Perl script for making a plot. I tried to plot some data 
> with "image" type plot of Gnuplot and also with "vectors" and both of
> these seemed to work perfectly fine separately. However, when I tried
> to do plot a data first with "image" type and then replot on the same
> graph using "vectors", it does not work properly and the vectors drawn
> by Gnuplot on top of the image have its arrows and the line as dashed 
> instead of a solid line. I tried doing this on Gnuplot alone and it works 
> fine, the error comes only when using PDL::Graphics::Gnuplot.
> 
> Looking forward to get any suggestions to help me solve the problem.
> 
> Thank You
> 
> Raksha 
> ICF- UNAM
> Mexico
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! 
> http://sdm.link/slashdot_______________________________________________
> pdl-general mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/pdl-general

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
pdl-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pdl-general

Reply via email to