plotting

Plotting a grouped 2 dimensional vector in MATLAB

I am trying to make a plot of a 2-dimensional vector (2D Plot). But I don't want all the datapoints to have the same color on the plot. Each datapoint corresponds to a group. I want to have different colors for each group of datapoints. class=[1 3 2 5 2 5 1 3 3 4 2 2 2] says each datapoint belongs to which group X=[x1,y1;x2,y2;x3,y...

making errorbars not clipped in matplotlib with Python

I am using matplotlib in Python to plot a line with errorbars as follows: plt.errorbar(xvalues, up_densities, yerr=ctl_sds, fmt='-^', lw=1.2, markersize=markersize, markeredgecolor=up_color, color=up_color, label="My label", clip_on=False) plt.xticks(xvalues) I set the ticks on the x-axis using "xticks". However, the error b...

Is there a way to show a 3-D surface plot in the browser?

I've got a bunch of data for 3-D surface plots. I want to build a quick web interface to let me browse through that data. Are there any (free) packages out there that can easily show surface plots? I found this question but the suggested libraries did not support surface plots. If it requires a plugin like flash / java that is fine. Thi...

How can I plot image data in Perl on Windows?

I would like to plot some image binary data on a grayscale matrix-like graph with custom values on axes. I'm using Perl on a Windows machine but I can't fine the right module to do this. I'm already using GD::Graph to plot other type of data but it seems unsuitable for this specific task. ...

Plot ellipse from rectangle

Hey folks, I have been looking all over the Web for a way to plot an ellipse from rectangle coordinates, that is, top-left corner (x, y) and size (width and height). The only ones I can find everywhere are based on the Midpoint/Bresenham algorithm and I can't use that because when working with integer pixels, I lose precisions because t...

how to create plots (non-flash) with mouse-over info boxes on the fly for the web?

Hi, I'm thinking about creating a tool to visualize scientific data on a website. For this, the user enters some query string and out comes a simple (x,y)-plot (similar to this) I know that using Matplotlib, one can generate graphics on the fly for python. However, this doesn't solve the need for some custom java-script code to display...

R multi plot log-log Label Problem

I'm trying to make a graph of a table and graph it in log space. First of all, plot(dat) gives me the grid of graphs Second of all, plot(dat, log="xy") gives me the correct plots of data in log space However, plot(dat, log="xy") ruins the main diagonal's labels of names(dat) R version 2.11.0 Sample Data: cold cold_contro...

In R draw two lines, with slopes double and half the value of the best fit line

I have data with a best fit line draw. I need to draw two other lines. One needs to have double the slope and the other need to have half the slope. Later I will use the region to differentially color points outside it as per: http://stackoverflow.com/questions/2687212/conditionally-colour-data-points-outside-of-confidence-bands-in-r ...

simple plot algorithm with autoscale

I need to implement a simple plotting component in C#(WPF to be more precise). What i have is a collection of data samples containing time (X axis) and a value (both double types). I have a drawing canvas of a fixed size (Width x Height) and a DrawLine method/function that can draw on it. The problem I am facing now is how do I draw the...

.NET Open Source Contour Plotting

I am looking for an Open Source .NET Library (or wrapper to a library) that will create contour plots from a set of values along a grid/mesh. ZedGraph is the closest thing I could find (http://zedgraph.org/). It would also be great if it could export to EPS. ...

Matlab how to show x,y coordinate

How to show both x,y coordinate mapped on image? x = 12; y = 54; plot(x,y,'+ b'); % this show only the "+" symbol. How to show the both coordinate and the "+" ...

Plotting question in Matlab

Is it possible to use the surf function to plot markers, e.g. surf(x,y,z,'some marker')? ...

Scale legend box border, dashed and dotted lines when the figure size is changed with matplotlib

I'm trying to use matplotlib to prepare some figures for publication. In order to make the font sizes match the text of the manuscript I'm trying to create the figure in the final size to begin with, so that I avoid scaling the figure when inserting it into the manuscript. The problem I'm having is that as the figure is then pretty smal...

Markers and the imagesc() function in matlab

How do you create a marker on a 2D image that is plotted using imagesc()? Is it even possible? ...

Matplotlib autoscale

I need to get a plot that fits the data automatically using matplotlib. This is the code I was given: import matplotlib.pyplot as plt from matplotlib.collections import LineCollection .... lines = LineCollection(mpl.line_holder, colors=mpl.colorholder , linestyle='solid') plt.axes().add_collection(lines) plt.axes().set_aspect('equal', '...

MATLAB plot x,y from Loop

I wonder why these two code doesn't produce the same plot? code 1: x=[2,5,7]; y=[10,4,3]; plot(x,y); code 2: x=[2,5,7]; y=[10,4,3]; for i=1:length(x) xx=x(i); yy=y(i); plot(xx,yy); end EDITED: How I can make the output of Code 2 similar to output in Code 1 ...

Matlab choose random color for plotting

I have 6 vectors which I want to plot. How I can make each plot with different color (random)? With the code below, the plot limited to one color for all six vectors. plot(x,y,'-rs','LineWidth',1,... 'MarkerEdgeColor','k',... 'MarkerFaceColor','g',... 'MarkerSize',5); ...

perl plotting using GD:Graph

hello, I have data like this. file1 date1 1 76.09 date10 10 87.09 date11 11 89.89 date2 2 66.5 date3 3 78.89 date4 4 87.98 date5 5 57 date6 6 57.98 date7 7 34.32 date8 8 45.76 date9 9 34.99 file2 date1 1 82.45 date2 2 86.23 file3 date1 1 65.76 ...

Matlab Adjusting coordinate

I have image which size was 600 * 600 and it was displayed on 800 * 800 pixel screen. The x,y coordinate in which the user look on screen was recorded in an array: x =[250,300,390,750,760]; y =[120,550,250,130,420]; In other program, I want to plot the x,y coordinate on the 600 * 600 image. The problem is that some of the x,y plot we...

How can I justify labels when plotting "with labels" in Gnuplot?

The following plot command produces a bar chart, and above each bar the value is plotted as label, formatted with gprintf: plot "data.txt" using 6:1 index 0 notitle with boxes linestyle 1,\ "data.txt" using 6:(0.7):(gprintf("%5.2f", $1)) index 0 notitle \ with labels font "Courier,34" rotate l...