|
|
| File Information |
| Description |
Computes goodness of fit for regression model given vector or matrix of target and output values.
USAGE:
[gf] = gfit2(t,y)
[gf] = gfit2(t,y,gFitMeasure)
INPUT
t: matrix or vector of target values for regression model
y: matrix or vector of output from regression model.
gFitMeasure: string or cell array of strings representing different forms of goodness of fit measure (eg. '1' - mean squarred error, '5' - mean absolute error, see below for details) . If gFitMeasure is not supplied, all statistics are returned as a vector. The following stats are returned:
'1' - mean squared error (mse)
'2' - normalised mean squared error (nmse)
'3' - root mean squared error (rmse)
'4' - normalised root mean squared error (nrmse)
'5' - mean absolute error (mae)
'6' - mean absolute relative error (mare)
'7' - coefficient of correlation (r)
'8' - coefficient of determination (d)
'9' - coefficient of efficiency (e)
'10' - maximum absolute error
'11' - maximum absolute relative error
OUTPUT:
gf: goodness of fit values between model output and target, either scalar, or vector one for each gFitMeasure chosen. |
| Acknowledgements |
The author wishes to acknowledge the following in the creation of this submission:
Goodness of Fit
|
| MATLAB release |
MATLAB 7.2 (R2006a)
|
|
Tags for This File
|
| Everyone's Tags |
|
| Tags I've Applied |
|
| Add New Tags |
Please login to tag files.
|
| Comments and Ratings (1) |
| 24 Nov 2008 |
David Yeo
|
|
|
| Updates |
| 07 Nov 2008 |
Fixed some bugs and spelling mistakes in comments, and added new output option. |
| 21 Nov 2008 |
Changed output for gfit2(t,y) now returns all available statistics as a vector rather than just the mean squared error (choice 1). Also made minor changes to comments and help section. |
| 24 Nov 2008 |
Actually uploaded new file this time, managed to forget to on last update. |
|
Public Submission Policy
NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for
all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content.
Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available
via MATLAB Central.
Read the complete Disclaimer prior to use.
Contact us at files@mathworks.com