<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/240170</link>
    <title>MATLAB Central Newsreader - Creating new user-defined model in Model-Based Calibration toolbox</title>
    <description>Feed for thread: Creating new user-defined model in Model-Based Calibration toolbox</description>
    <language>en-us</language>
    <copyright>&amp;copy;1994-2012 by MathWorks, Inc.</copyright>
    <webmaster>webmaster@mathworks.com</webmaster>
    <generator>MATLAB Central Newsreader</generator>
    <docs>http://blogs.law.harvard.edu/tech/rss</docs>
    <ttl>60</ttl>
    <image>
      <title>MathWorks</title>
      <url>http://www.mathworks.com/images/membrane_icon.gif</url>
    </image>
    <item>
      <pubDate>Sun, 30 Nov 2008 18:33:02 -0500</pubDate>
      <title>Creating new user-defined model in Model-Based Calibration toolbox</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/240170#614021</link>
      <author>Mohammad Monfared</author>
      <description>Hi,&lt;br&gt;
&lt;br&gt;
In Model-Based Calibration toolbox, I want to define a new model as a user-defined model. My model is going to use the &quot;gamcdf&quot; function, as its function. I've passed the almoste simple steps (by means of a template file called, weibul.m ) described in the help section. But when I want to checkin it:&lt;br&gt;
&lt;br&gt;
checkin(xregusermod, 'gammacdf', [0.1:0.01:0.2]'); % my new model is named, gammacdf&lt;br&gt;
&lt;br&gt;
this error appears:&lt;br&gt;
&lt;br&gt;
??? Error using ==&amp;gt; minus&lt;br&gt;
Matrix dimensions must agree.&lt;br&gt;
&lt;br&gt;
I can't recognize from where, this arises. Could anybody give some advice or make it for me?&lt;br&gt;
&lt;br&gt;
thanks in advance,&lt;br&gt;
Mohammad</description>
    </item>
    <item>
      <pubDate>Mon, 01 Dec 2008 14:55:03 -0500</pubDate>
      <title>Re: Creating new user-defined model in Model-Based Calibration toolbox</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/240170#614179</link>
      <author>Mohammad Monfared</author>
      <description>After making some corrections, I ran into this error:&lt;br&gt;
&lt;br&gt;
??? Error using ==&amp;gt; localusermod.features at 48&lt;br&gt;
Invalid response feature definition for user-defined model&lt;br&gt;
&lt;br&gt;
the function &quot;i_rfvals(U,b)&quot;, is in the optional section of the .m file. I don't know what are response feature, and especially its definition for gamcdf.&lt;br&gt;
&lt;br&gt;
any suggestion?&lt;br&gt;
&lt;br&gt;
Mohammad,</description>
    </item>
    <item>
      <pubDate>Tue, 02 Dec 2008 13:38:01 -0500</pubDate>
      <title>Re: Creating new user-defined model in Model-Based Calibration toolbox</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/240170#614429</link>
      <author>Ian Noell</author>
      <description>Hi Mohammed,&lt;br&gt;
&lt;br&gt;
The function weibul.m is setup for the weibul model and contains functionality specific to that model. If you delete the code in the subfunction i_rfvals and replace it with &lt;br&gt;
&lt;br&gt;
function [rf,dG]= i_rfvals(U,b) %#ok&amp;lt;INUSL,DEFNU&amp;gt;&lt;br&gt;
&lt;br&gt;
rf = [];&lt;br&gt;
dG = [];&lt;br&gt;
&lt;br&gt;
it should work. There are other functions in weibul that will be invalid for your model. If you are not certain what to do I suggest you replace all the optional functions with the ones in xregusermod/functemplate.&lt;br&gt;
&lt;br&gt;
I recommend that you start from the blank template file xregusermod/functemplate when writing a user-defined model. weibul is documented as an example of user-defined models rather than a template.&lt;br&gt;
&lt;br&gt;
I'd be happy to help you further if you send me your user-defined model and let me know what version of MBC you are using.&lt;br&gt;
&lt;br&gt;
Best regards,&lt;br&gt;
Ian</description>
    </item>
    <item>
      <pubDate>Thu, 04 Dec 2008 15:44:02 -0500</pubDate>
      <title>Re: Creating new user-defined model in Model-Based Calibration toolbox</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/240170#615067</link>
      <author>Mohammad Monfared</author>
      <description>Hi &amp; So thanks Ian,&lt;br&gt;
&lt;br&gt;
I've build my models using the template_function as you said, and it was successful !&lt;br&gt;
I have another question, if you would help. In the model setup section of mbcmodel, I've made a two-stage, multiple-model with two model included in the local model. And I like to compare these two ones according to the AICc criterion. In the 431 observations, there are obs where model1 is preferred and obs where model2. How can I count the successful obs for model1 and model2?&lt;br&gt;
&lt;br&gt;
Thanks in advanced,&lt;br&gt;
Mohammad</description>
    </item>
    <item>
      <pubDate>Tue, 16 Dec 2008 11:12:02 -0500</pubDate>
      <title>Re: Creating new user-defined model in Model-Based Calibration toolbox</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/240170#617336</link>
      <author>Ian Noell</author>
      <description>Hi Mohammed,&lt;br&gt;
&lt;br&gt;
There is not a simple way to get a list of all the selected models from the GUI. At the moment the simplest way for you to find out this information is using the command-line API. &lt;br&gt;
&lt;br&gt;
I will make an enhancement request to add a the ability to get this information from the GUI.&lt;br&gt;
&lt;br&gt;
Best regards,&lt;br&gt;
Ian&lt;br&gt;
&lt;br&gt;
&quot;Mohammad Monfared&quot; &amp;lt;gohardoust@gmail.com&amp;gt; wrote in message &amp;lt;gh8ts2$kba$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; Hi &amp; So thanks Ian,&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; I've build my models using the template_function as you said, and it was successful !&lt;br&gt;
&amp;gt; I have another question, if you would help. In the model setup section of mbcmodel, I've made a two-stage, multiple-model with two model included in the local model. And I like to compare these two ones according to the AICc criterion. In the 431 observations, there are obs where model1 is preferred and obs where model2. How can I count the successful obs for model1 and model2?&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Thanks in advanced,&lt;br&gt;
&amp;gt; Mohammad</description>
    </item>
  </channel>
</rss>

