Group Abstract Group Abstract

Message Boards Message Boards

0
|
11.6K Views
|
4 Replies
|
1 Total Like
View groups...
Share
Share this post:

Help with data import into FindFit ? Or defining data import as a list?

Posted 11 years ago
Attachments:
POSTED BY: Renee Dale
4 Replies
Posted 11 years ago

Ok yay got rid of that error thank you!! Yea my data is only for w, please tell me there's some simple solution to that? .... Here's what I tried:

 fit = FindFit[data[[1, 1]], 
   model[a, b, q, v, z, y, d][
    w], {{a, 54, 7, 150}, {b, 220}, {q, .16, .01, 
     1.5}, {v, .05, .04, .06}, {z, 
     6000000}, {y, .05, .04, .06}, {d, .0003}}, w, PrecisionGoal -> 4,
    AccuracyGoal -> 4];

(I also added ranges for the parameters). Now I'm getting:

"The function value xx is not a real number at xx"

Does it just not like my initial guesses?

POSTED BY: Renee Dale

Once you get the data is the right shape, the next thing you will run into is this message: FindFit::fitc: Number of coordinates (1) is not equal to the number of variables (4). >>

FindFit over independent variables labeled {s, w, r, c} will be expecting data of the form {{s1, w1, r1, c1, val1}, {s2, w2, r2, c2, val2}, .. }

Posted 11 years ago

So then why am I getting that error for FindFit? Is it because of something else I'm doing wrong and not actually the list stuff?

POSTED BY: Renee Dale

When you Import this file, it will come through as a List expression. There is no need to wrap it in another List. In fact the XLS file, having multiple pages, will already have an extra List layer. ListPlot will work, if you strip these both.

ListPlot[data[[1, 1]], PlotRange -> All]
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard