Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

Thanks, that makes the layout of the data clear.

Now that I've thought about it, I've never seen a polar plot distorted in a way you describe. The polar axis is in decibels, so it already uses logarithmic scale - by "making the outer donuts larger", as you say, you actually want to undo the logarithmic scaling, at least partially. In any case, I see this as a cosmetic alteration that may be harmful, because it changes the shape of the curve you want to show, without good reason.

With that in mind, here is a gnuplot script that produces a graph close to what you want:

set polar set rr [-40:10] set rtics 10 unset border unset xtics unset ytics set grid lt 1 lc rgb "blue" f(x) = (x+50)**2 g(x) = sqrt(x)-50 set nonlinear r via f(r) inverse g(r) plot '/tmp/foo.n2p' u ($0>0&&$0<=361 ? $0*pi/180. : 1/0):1 w l lw 2 n +otit

The scaling function (that determines the spacing of the grid circles) is a square function (f(x) in the script) as opposed to exponential. You could use this function in your script if you prefer to stay with your pure perl solution.


In reply to Re^3: Logarithmic Scale by kikuchiyo
in thread Logarithmic Scale by aplonis

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (7)
As of 2024-04-18 09:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found