PDL::Graphics::Prima

An interactive graph widget for PDL and Prima
Download

PDL::Graphics::Prima Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • David Mertens
  • Publisher web site:
  • http://search.cpan.org/~dcmertens/

PDL::Graphics::Prima Tags


PDL::Graphics::Prima Description

PDL::Graphics::Prima is a plotting interface for creating and exploring 2D data visualizations. The core of this interace is a Plot widget that can be incorporated into Prima applications.SIMPLE SYNOPSIS use PDL::Graphics::Prima::Simple; use PDL; # Generate some data - a sine curve my $x = sequence(100) / 20; my $y = sin($x); # Draw a point at each x/y pair: blob_plot($x, $y); # Draw a line connecting each x/y pair: line_plot($x, $y); # Draw a histogram: my ($bin_centers, $heights) = $y->hist; hist_plot($bin_centers, $heights); hist_plot($y->hist); # equivalent # Generate some data - a wavy pattern my $image = sin(sequence(100)/10) + sin(sequence(100)/20)->transpose; # Generate a greyscale image: matrix_plot($image); # Set the left, right, bottom, top matrix_plot(, , $image); # Use the more general plot for multiple datasets # and more plotting features: my $colors = pal::Rainbow()->apply($x); plot( -lines => ds::Pair($x, $y), -color_blobs => ds::Pair($x, $y + 1, colors => $colors, plotType => pt::Blobs ), x => { label => 'Time' }, y => { label => 'Sine' }, );WIDGET SYNOPSIS use PDL; use Prima qw(Application); use PDL::Graphics::Prima; my $t_data = sequence(6) / 0.5 + 1; my $y_data = exp($t_data); my $wDisplay = Prima::MainWindow->create( text => 'Graph Test', size => , ); $wDisplay->insert('Plot', -function => ds::Func(\&PDL::exp, color => cl::Blue), -data => ds::Pair($t_data, $y_data, color => cl::Red), pack => { fill => 'both', expand => 1}, ); run Prima;Product's homepage


PDL::Graphics::Prima Related Software