Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How to Import data from excel and use them to Plot windrose instead?

Example, {{Strength, Angle(degrees)}..}

data = {{11.84,24.70}, {13.64,0}, {14.11,24.70}, {11.92,16.20}, {7.95,337.10}, 
        {8.34,326.60}, {7.85,335.40}, {8.90,6.30}, {10.43,338.40}, {10.36,325.60}, 
        {10.93,332.00}, {14.78,318.20}, {14.30,345.30}};

$0$ is North.

share|improve this question
up vote 9 down vote accepted

Let's say you've managed to import the data from excel and you want to transform list:

{{strength, angle}...}

so it fits the methods from the Q&A: How to create a wind rose with Mathematica?. There are couple of operations you must do:

r = Table[{RandomReal[{0, 20}], RandomReal[{0, 360}]}, {t, 0, 15}]; (*sample data*)
  • Your list is not sorted with the angle as it need to be for proper joining the points.
  • ListPolarPlot needs to get {angle, radius}...} type of list so in the second step we are doing that.
  • last step is only in order to close the line.

r = SortBy[r, Last]; 
r = {#2 Degree, #} & @@@ r;
AppendTo[r, r[[1]]];

ListPolarPlot[r, BaseStyle -> {Bold, 16}, Joined -> True, PlotMarkers -> Automatic, 
                 PolarGridLines -> {Range[0, 2 Pi, Pi/18], Automatic}, 
                 PolarTicks -> {"Direction", Automatic}, PolarAxes -> True, 
                 PlotStyle -> {PointSize[Large], Thick}, 
                 PolarAxesOrigin -> {Pi/2, 20}, PlotRange -> All]

enter image description here

share|improve this answer
TNX. one more question: how to move lines between dots? – StartX Oct 31 '13 at 17:22
Up in example we have 16 dot's conected with line's. I don't need line's, I need only dot's. Sorry for stupid question's. – StartX Nov 2 '13 at 19:57
@StartX just skip the Joined->True part :) – Kuba Nov 2 '13 at 20:18

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.