Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Home
- /
- Analytics
- /
- Stat Procs
- /
- How do I fit an equation?

Options

- RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

🔒 This topic is **solved** and **locked**.
Need further help from the community? Please
sign in and ask a **new** question.

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Posted 06-08-2019 01:26 PM
(316 views)

I have to a model

threshold = 100 -2*deltat + c1*sigma^a + c2*deltat^2 + c3*sigma^c * deltat^d

where I know 0<threshold<100 as it is in all my datapoints (https://pastebin.com/3pYiNFf1)

To do this I run the following code (and I am fully aware this approach is incredibly stupid/ridiculous but I can't think of anything better) using the nlmixed procedure with as model the binomial distribution with 100 trials, and succes chance hopefully threshold/100.

PROC NLMIXED data=BEP;

PARMS c1=-1, c2=0, c3=0, a=1, b=1, c=1, d=1;

p = (100 - 2*deltat + c1*sigma**(a) + c2*deltat**(b) + c3*sigma**(c) * deltat**(d))/100;

model threshold ~ binomial(100,p);

run;

However when running this I get no output and the log says

NOTE: Execution error for observation 1.

NOTE: The SAS System stopped processing this step because of errors.

Although I do get results if I remove the parameters a,b,c,d, I don't get any results when I include them.

This was run using SAS university edition version 3.8

1 ACCEPTED SOLUTION

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Run NLMIXED with option trace to get debug info. The problem is related to cases where sigma=0. NLMIXED is trying to take the log of sigma and fails. You can get convergence by replacing sigma=0 by sigma=0.01.

With sigma=0.01, the results indicate that your model is overparameterized, likely because of the two terms involving sigma with different exponents. Just a guess.

PG

1 REPLY 1

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Run NLMIXED with option trace to get debug info. The problem is related to cases where sigma=0. NLMIXED is trying to take the log of sigma and fails. You can get convergence by replacing sigma=0 by sigma=0.01.

With sigma=0.01, the results indicate that your model is overparameterized, likely because of the two terms involving sigma with different exponents. Just a guess.

PG

📢

**ANNOUNCEMENT**

The early bird rate has been extended! Register by March 18 for just $695 - $100 off the standard rate.

Check out the agenda and get ready for a jam-packed event featuring workshops, super demos, breakout sessions, roundtables, inspiring keynotes and incredible networking events.** **

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.