# Tag Info

3

ptsech = {{0, 0}, {30., 0}, {54.366, 0.00901776}, {67.0222, 0.477768}, {70.7722, 4.22777}, {71.241, 16.884}, {71.25, 41.25}, {71.25, 71.25}, {71.259, 95.616}, {71.7278, 108.272}, {75.4778, 112.022}, {88.134, 112.491}, {112.5, 112.5}, {142.5, 112.5}, {166.866, 112.509}, {179.522, 112.978}, {183.272, 116.728}, {183.741, 129.384}, {183.75, ...

3

Just for the records: This is how I would write the code. At least the loading of data is now optimized for minimizing communication overhead. stocks7 = {"GOOG", "FB", "AMZN", "NFLX", "AAPL", "MSFT", "TSLA"}; n = Length[stocks7]; α = {2015, 1, 1}; β = {2017, 12, 31}; data0 = FinancialData[stocks7, "Close", {α, β}]; data = DeveloperToPackedArray[...

4

colors = ColorData[97] /@ {1, 2}; Plot[Min[{1 - 1/R, R^3 - 1}], {R, 0, 5}, PlotRange -> {-2, 2}, MeshFunctions -> {#^3 - 1 - (1 - 1/#) &}, Mesh -> {{0}}, MeshShading -> Reverse[colors], PlotLegends -> LineLegend[colors, {"One", "Two"}]] Alternatively, let pw = PiecewiseExpand @ Min[{1 - 1/R, R^3 - 1}] and use pw as the first ...

2

Edit: The suggestion by Michael E2 has been taken into account. If you don't want different colours for the different regions the following does the trick for you Plot[Piecewise[{{x^3, -10 < x < 0}, {Log[x], 0 < x < 5}, {Sqrt[x], 5 < x < 10}}], {x, -10, 10}, PlotRange -> {{-1.5, 1.5}, {-2, 1}}, Exclusions -> None] If you want ...

2

May be you can learn from that example. (I just wanted to avoid waiting for the long caclulations in your post.) model = a Exp[-b ((x - x0)^2 + (y - y0)^2)]; pl = Plot3D[1.2 Exp[-34 ((x - .02)^2 + (y - .07)^2)], {x, 0, 1}, {y, 0, 1}, PlotRange -> All, PlotStyle -> Opacity[.5]]; data1 = Table[{x, 0, 1.2 Exp[-34 ((x - .02)^2 + (0 - ....

1

For such a simple model, you don't need explicit NonlinearModelFit since you can just use the trasformed predictors in LinearModelFit as follows to achieve the desired fit: ClearAll[fittedFunction]; fittedFunction=LinearModelFit[Transpose@{ω,θ},{1,x^-4},x]["Function"]; Now you can call this function outside your existing domain for extrapolation: ...

1

Given n==4 you might try fit = NonlinearModelFit[ωθ, θ0 + c/ω^4 , {θ0, c, n}, ω] Normal[fit] (*36.0214 - 9577.97/ω^4*) This approach might be extended to although fit n (more data necessary)

1

This is a kind of a comment because I see this topic has a bit unfriendly description in the docs. The meaning is as follows: ARIMAProcess[start, {AR}, D, {MA}, [Sigma]^2] were AR stands for autoregressive process, D stands for difference and MA for moving average (those AR and MA could be matrices). Sigma^2 stands for variance. Most confusing is start, ...

2

As I mentioned in my comment, it looks like the problem is the Log trying to evaluate when the argument is negative. Adding Abs in the argument might help. Also, the model itself doesn't seem to match the data: are you sure that data should follow that function? It looks to me that Exp[-x^(1/2)] fits the data better: fitfunction[x_] := b*Exp[-c*x^(1/2) + ...

0

Thanking a user of WolframCommunity (but thanks also to those who answered and helped me here), I put the solution to the problem. NIntegrate only works when the boundaries are numerical. Therefore when you use it as a fit function you have to be sure the function only evaluates if the input parameters are numerical. fm[x_, y_, t_, b_, l_, d_] /; ...

Top 50 recent answers are included