Error in plotting points with semilog scale

asked 2015-08-13 15:58:55 -0600

sibilant gravatar image

I have a few integer points and would like to plot them in semilogx scale. The following example shows what works great:

sage: listofpoints = [(1, 2), (10, 3), (100, 4)]
sage: plot(point(listofpoints), scale = "semilogx")

However, for listofpoints = [(3, 1), (4, 2)], I get an error with ValueError "Either expand the range of the independent variable to allow two different integer powers of your base, or change your base to a smaller number."

This is a minimal working example, and my listofpoints is actually much longer. My aim is to guess whether the function connecting the points grows logarithmically or faster than that by eyeballing the graph, so I don't really care what base the logx scale is in.

Is this a known problem? Can someone suggest a quick fix? I'm using Sage Version 6.2, Release Date: 2014-05-06, in command line.

Thank you!

edit retag flag offensive close merge delete


No error with Sage Cell Server! May be you should use a newer version of Sage.

ndomes gravatar imagendomes ( 2015-08-13 16:24:04 -0600 )edit

Works for me on sage 6.9.beta2.

FrédéricC gravatar imageFrédéricC ( 2015-08-14 02:06:20 -0600 )edit