nls

Dojo 1.9 build 'multipleDefine' error while loading locale

只谈情不闲聊 提交于 2019-12-05 04:39:52
My dojo application breaks after building, during loading the app, throwing 'multipleDefine' and giving this error: Error {src: "dojoLoader", info: Object} Message: multipleDefine info: Object {pid: "dojo", mid: "dojo/nls/dojo_en-us", pack: Object, url: "dojo/nls/dojo_en-us.js", executed: 5…} Here is my profile: var profile = { // `basePath` is relative to the directory containing this profile file; in this case, it is being set to the // src/ directory, which is the same place as the `baseUrl` directory in the loader configuration. (If you change // this, you will also need to update run.js.)

Failing to do fitting with non linear fitting methods (nlsLM, nlxb and wrapnls)

懵懂的女人 提交于 2019-12-04 20:07:04
I have a nls fitting task that I wanted to do with R. My first attempt to do this here and as @Roland pointed out "The point is that complex models are difficult to fit. The more so, the less the data supports the model until it become impossible. You might be able to fit this, if you had extremely good starting values." I can agree with @Roland but if excel can do this fitting why not R cannot do? Basically this fitting can be done with Excel's GRG Nonlinear solver but the process is very time consuming and sometimes fitting is not good. (since there are a lots of data in reality). here is my

R - Confidence bands for exponential model (nls) in basic graphics

蓝咒 提交于 2019-12-04 19:23:22
I'm trying to plot a exponential curve (nls object), and its confidence bands. I could easily did in ggplot following the Ben Bolker reply in this post . But I'd like to plot it in the basic graphics style, (also with the shaped polygon) df <- structure(list(x = c(0.53, 0.2, 0.25, 0.36, 0.46, 0.5, 0.14, 0.42, 0.53, 0.59, 0.58, 0.54, 0.2, 0.25, 0.37, 0.47, 0.5, 0.14, 0.42, 0.53, 0.59, 0.58, 0.5, 0.16, 0.21, 0.33, 0.43, 0.46, 0.1, 0.38, 0.49, 0.55, 0.54), y = c(63, 10, 15, 26, 34, 32, 16, 31,26, 37, 50, 37, 7, 22, 13, 21, 43, 22, 41, 43, 26, 53, 45, 7, 12, 25, 23, 31, 19, 37, 24, 50, 40)),

Visualizing multiple curves in ggplot from bootstrapping, curve fitting

守給你的承諾、 提交于 2019-12-04 19:09:04
I have time series data that is well modeled using a sinusoidal curve. I'd like to visualize the uncertainty in the fitted model using bootstrapping. I adapted the approach from here. I am also interested in this approach too, using nlsBoot . I can get the first approach to run, but the resulting plot contains curves that are not continuous, but jagged. library(dplyr) library(broom) library(ggplot2) xdata <- c(-35.98, -34.74, -33.46, -32.04, -30.86, -29.64, -28.50, -27.29, -26.00, -24.77, -23.57, -22.21, -21.19, -20.16, -18.77, -17.57, -16.47, -15.35, -14.40, -13.09, -11.90, -10.47, -9.95,-8

How to find good start values for nls function?

夙愿已清 提交于 2019-12-04 11:40:09
问题 I don't understand why I can't have a nls function for these data. I have tried with a lot of different start values and I have always the same error. Here is what I have been doing: expFct2 = function (x, a, b,c) { a*(1-exp(-x/b)) + c } vec_x <- c(77.87,87.76,68.6,66.29) vec_y <- c(1,1,0.8,0.6) dt <- data.frame(vec_x=vec_x,vec_y=vec_y) ggplot(data = dt,aes(x = vec_x, y = vec_y)) + geom_point() + geom_smooth(data=dt, method="nls", formula=y~expFct2(x, a, b, c), se=F, start=list(a=1, b=75, c=

Fitting a function in R

柔情痞子 提交于 2019-12-04 10:48:40
问题 I have a few datapoints (x and y) that seem to have a logarithmic relationship. > mydata x y 1 0 123 2 2 116 3 4 113 4 15 100 5 48 87 6 75 84 7 122 77 > qplot(x, y, data=mydata, geom="line") Now I would like to find an underlying function that fits the graph and allows me to infer other datapoints (i.e. 3 or 82 ). I read about lm and nls but I'm not getting anywhere really. At first, I created a function of which I thought it resembled the plot the most: f <- function(x, a, b) { a * exp(b *-x

Error: Results are not data frames at positions:

安稳与你 提交于 2019-12-04 05:19:30
问题 I am trying to run a fitting function on a rather large data frame, grouped by a variable named "big_group" and 'small_group' . In particular, I am trying to get predictions and coefs values of every small_group inside of big_group . That is, I'm trying to add these new columns to my new data.frame at the end of do({ function. Some of the groups of this data cannot be fitted due to either lack of data points or "singular gradient matrix at initial parameter estimates" error. So, I used

Dojo custom build with NLS / localisation

只谈情不闲聊 提交于 2019-12-04 04:37:33
I have a problem implementing a cross domain custom build in Dojo. The situation is as follows: i have a pretty large application, with a good number of localisation bundles, so basicly the directory structures is like core\ (my module) nls\ fr\ en\ .... When building my module the result is a big core.js/core.xd.js file, which, bien sur, does not contain the localisations. In the localisation nls directories (en/fr/etc) i find after the build each bundle builded/minified, and a bigger file for each language, core_fr.js/core_en.fs, which contains only Dojo/Dijit related strings. so my build

Dynamic length on number format in to_number Oracle SQL

若如初见. 提交于 2019-12-04 04:16:57
问题 I have a table with numbers stored as varchar2 with '.' as decimal separator (e.g. '5.92843'). I want to calculate with these numbers using ',' as that is the system default and have used the following to_number to do this: TO_NUMBER(number,'99999D9999','NLS_NUMERIC_CHARACTERS = ''.,''') My problem is that some numbers can be very long, as the field is VARCHAR2(100) , and when it is longer than my defined format, my to_number fails with a ORA-01722 . Is there any way I can define a dynamic

Modifying a curve to prevent singular gradient matrix at initial parameter estimates

杀马特。学长 韩版系。学妹 提交于 2019-12-04 03:20:51
问题 I want to use y=a^(b^x) to fit the data below, y <- c(1.0385, 1.0195, 1.0176, 1.0100, 1.0090, 1.0079, 1.0068, 1.0099, 1.0038) x <- c(3,4,5,6,7,8,9,10,11) data <- data.frame(x,y) When I use the non-linear least squares procedure, f <- function(x,a,b) {a^(b^x)} (m <- nls(y ~ f(x,a,b), data = data, start = c(a=1, b=0.5))) it produces an error: singular gradient matrix at initial parameter estimates. The result is roughly a = 1.1466, b = 0.6415, so there shouldn't be a problem with intial