About 3,970,000 results
Open links in new tab
  1. numpy - How to do exponential and logarithmic curve fitting in …

    Aug 8, 2010 · 250 I have a set of data and I want to compare which line describes it best (polynomials of different orders, exponential or logarithmic). I use Python and Numpy and for …

  2. How do you do natural logs (e.g. "ln()") with numpy in Python?

    Also like MATLAB/Octave, Numpy does not offer a logarithmic function for an arbitrary base. If you find log confusing you can create your own object ln that refers to the numpy.log function:

  3. How to write a simple logarithm function without math.h?

    Apr 11, 2023 · That means if you have a function that computes the binary logarithm, you can use it to deduce the decimal logarithm or the natural (base e) logarithm. In particular, log10(x) = …

  4. regression - How can I fit a logarithmic model to my data in R? nls …

    Apr 19, 2023 · I tried a logarithmic function based on the visual distribution of the data points. I've tried using both lm and nls functions, but when I visualize the fit it's still linear and I don't …

  5. Why the cost function of logistic regression has a logarithmic …

    Oct 7, 2015 · Although a possible definition of the cost function could be the mean of the Euclidean distance between the hypothesis h_θ (x) and the actual value y among all the m …

  6. What is the complexity of the log function? - Stack Overflow

    Sep 6, 2011 · This really depends on the domain of what values you want to compute a logarithm of. For IEEE doubles, many processors can take logarithms in a single assembly instruction; …

  7. Fit a logarithmic curve to data points and extrapolate out in numpy

    Apr 20, 2018 · I would like to plot these points, and fit a curve to them that shows what value of x would be required to make y = 100.0 (y values are percentages). Here is what I have tried, but …

  8. python - Plotting the logarithm of a function - Stack Overflow

    Aug 23, 2023 · Is your problem calculating the logarithm base 10 or plotting the values? If the latter, how is that different from plotting anything else? Also, your f(x,a) is a function of two …

  9. math - Convert Linear scale to Logarithmic - Stack Overflow

    Oct 20, 2013 · You asked to convert linear to logarithmic, and you just plug the numbers into the formula. In this case, the linear input of 5.00 would become 1.02 on the logarithmic scale.

  10. Python using curve_fit to fit a logarithmic function

    Jan 18, 2020 · I'm trying to fit a log curve using curve_fit, assuming it follows Y=a*ln(X)+b, but the fitted data still looks off. Right now I'm using the following code: from scipy.optimize import …