Mathematica Asked on August 29, 2021
I have five data sets, {4.88281 10^(-5), 0.0788}, {9.76563 10^(-5), 0.1014}, {0.000195313, 0.12455}, {0.000390625, 0.15594}, {0.0015625, 0.18587}. I was using EXCEL to add the trendline, but the x intercept is a negative value. I wanted to fit the trendline close to zero but don’t include (0,0) in my plot, can I get this done with Mathematica?
Thanks!
data = {{4.88281 10^(-5), 0.0788}, {9.76563 10^(-5), 0.1014}, {0.000195313, 0.12455},
{0.000390625, 0.15594}, {0.0015625, 0.18587}};
lm = LinearModelFit[data, Log[x], x]
Show[ListLogLinearPlot[data],
LogLinearPlot[lm[x], {x, Min[data[[All, 1]]], Max[data[[All, 1]]]}]]
Show[ListPlot[data],
Plot[lm[x], {x, 0, Max[data[[All, 1]]]}, PlotRange -> All]]
Answered by JimB on August 29, 2021
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP