Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
1997
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 1997

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Plot bug?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg6366] [mg6366] Re: [mg6354] Plot bug?
  • From: "Preferred Customer" <sherman.reed at worldnet.att.net>
  • Date: Fri, 14 Mar 1997 14:53:47 -0500 (EST)
  • Sender: owner-wri-mathgroup at wolfram.com

Brad, 
your code failed on 2.2.3 and 3.0 for me also, but when I changed the
Ln command to Log, the code worked fine on both.  As far as I could see
the plots were identical.
sherman reed

----------
> From: Brad Miller <bmiller at illigal.ge.uiuc.edu>
To: mathgroup at smc.vnet.net
> To: mathgroup at smc.vnet.net
> Subject: [mg6366] [mg6366] [mg6354] Plot bug?
> Date: Thursday, March 13, 1997 12:20 AM
> 
> Hi,
> 	I am running the new version of mathematica (3.0), and some
> code that worked under the old version (2.x?) is not working.
> 
> pseudo-mathematica session
> *****************************************************
> 1> Needs["Statistics`ContinuousDistributions`"]
> 
> 2> PopRatio[pratio_]:=	
> 	Module[{p}, p=CDF[NormalDistribution[0,1],pratio];
> 	- 2 pratio / Ln[(1-p)/p]
> 	]
> 
> 3> Plot[PopRatio[x],{x,.000001,.7}]
> 
> Errors: "Plot::plnr : PopRatio[pratio] is not a machine-size real
>            number at pratio = 0.0283978535340494791"
>   and many other points also say not a machine-size real number
> *****************************************************
> 
> 
> Doing a PopRatio[0.0283978535340494791] on the reported bad number
> produces the correct PopRatio return value - it does not blow up.  So,
> I'm surmising the problem is in the Plot cmd?
> 
> This exact fn worked in mathematica 2.x - result should be a plot from
> around 1.26 to 1.2 - there are no discontinuities in the plot.
> 
> Any suggestions on how to get PopRatio to plot correctly?
> 
> 
> thanks,
> Brad
> 
>
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
> % Brad L. Miller                                                        
%
> % University of Illinois at Urbana-Champaign                            
%
> % ph:  (217) 333-2346    email: bmiller at uiuc.edu                        
%
> % fax: (217) 244-5705    web:   http://www-illigal.ge.uiuc.edu/~bmiller 
%
> %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


  • Prev by Date: Re: NonlinearFit in the Mma on-line book
  • Next by Date: Re: Coords of intersecting lines...
  • Previous by thread: Plot bug?
  • Next by thread: Numerical Left Eigenvectors