[Date Index]
[Thread Index]
[Author Index]
Re: change the base of the Log[] used by LogLogPlot?
*To*: mathgroup at smc.vnet.net
*Subject*: [mg112944] Re: change the base of the Log[] used by LogLogPlot?
*From*: "Nasser M. Abbasi" <nma at 12000.org>
*Date*: Thu, 7 Oct 2010 03:36:18 -0400 (EDT)
On 10/6/2010 8:29 AM, Brett Champion wrote:
> On Oct 6, 2010, at 2:15 AM, Nasser M. Abbasi wrote:
>
>> Mathematica experts:
>>
>> I want to use LogLogPlot, say as in LogLogPlot[x,{x,.1,1}], but I want
>> the Log to be in base 10, not in base e as the default used.
>>
>> Looking at the doc, I can't see it. No option to change the base.
>>
>> I can ofcourse build my own data, and use ListPlot, but LogLogPlot
>> handles the ticks better automatically and it samples better. Same
>> question applies for LogPlot, LogLinearPlot, ListLogPlot,
>> ListLogLinearPlot, etc...
>>
>> I am sure this is hidden somewhere in the documentation :)
>>
>
> Nope. LogPlot uses Log.
>
> I'm curious as to why you want to switch to Log10 since the plot would
> end up looking exactly the same.
>
hi;
If both the x and y are in log scale, yes, the look the same (but ticks
are not for all the bases).
---- loglog-------
x = {1, 2, 3, 4};
data1 = Table[{Log[10,x], Log[10, x]}, {x, 1, 10}];
data2 = Table[{Log[x], Log[x]}, {x, 1, 10}];
Show[{ListPlot[data1, PlotStyle -> Red, Joined -> True],
ListPlot[data2, Joined -> True]}]
---------------
But not if x is linear and y is log, then the plot are not the same:
----loglinear-------
x = {1, 2, 3, 4};
data1 = Table[{x, Log[10, x]}, {x, 1, 10}];
data2 = Table[{x, Log[x]}, {x, 1, 10}];
Show[{ListPlot[data1, PlotStyle -> Red, Joined -> True],
ListPlot[data2, Joined -> True]}]
---------------------
any way, not too important, just was wondering ;)
thanks,
--Nasser
Prev by Date:
**Re: change the base of the Log[] used by LogLogPlot?**
Next by Date:
**Re: Find minimum number of operations**
Previous by thread:
**Re: change the base of the Log[] used by LogLogPlot?**
Next by thread:
**Re: change the base of the Log[] used by LogLogPlot?**
| |