plotDiagnostics
Class: NonLinearModel
Plot diagnostics of nonlinear regression model
Syntax
plotDiagnostics(mdl)
plotDiagnostics(mdl,plottype)
plotDiagnostics(mdl,plottype,Name,Value)
h = plotDiagnostics(___)
Description
plotDiagnostics(
creates a leverage plot of the
nonlinear regression model (mdl
)mdl
) observations. A dotted line in
the plot represents the recommended threshold values.
plotDiagnostics(
specifies the type of observation diagnostics mdl
,plottype
)plottype
.
plotDiagnostics(
specifies the graphical properties of diagnostic data points using one or more
name-value arguments. For example, you can specify the marker symbol and size for the
data points.mdl
,plottype
,Name,Value
)
returns
graphics objects for the lines or contour in the plot using any of the input argument
combinations in the previous syntaxes. Use h
= plotDiagnostics(___)h
to modify the
properties of a specific line or contour after you create the plot. For a list of
properties, see Line Properties and Contour Properties.
Input Arguments
|
Nonlinear regression model, constructed by | ||||||
|
Character vector or string scalar specifying the type of plot:
Default: |
Name-Value Arguments
Specify optional pairs of arguments as
Name1=Value1,...,NameN=ValueN
, where Name
is
the argument name and Value
is the corresponding value.
Name-value arguments must appear after other arguments, but the order of the
pairs does not matter.
Before R2021a, use commas to separate each name and value, and enclose
Name
in quotes.
Note
The graphical properties listed here are only a subset. For a complete list, see Line Properties. The specified properties determine the appearance of diagnostic data points.
|
Color of the line or marker, specified as an RGB triplet, hexadecimal color code, color name, or short name for one of the color options listed in the following table. For a custom color, specify an RGB triplet or a hexadecimal color code.
Alternatively, you can specify some common colors by name. This table lists the named color options, the equivalent RGB triplets, and hexadecimal color codes.
Here are the RGB triplets and hexadecimal color codes for the default colors MATLAB® uses in many types of plots.
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Width of the line or edges of filled area, in points, a positive scalar. One point is 1/72 inch. Default: | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Marker symbol, specified as one of the values in this table.
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Marker outline color, specified as an RGB triplet, hexadecimal color code, color name, or
short name for one of the color options listed in the | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Fill color for filled markers, specified as an RGB triplet, hexadecimal color code, color
name, or short name for one of the color options listed in the
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Size of the marker in points, a strictly positive scalar. One point is 1/72 inch. |
Output Arguments
|
Graphics objects corresponding to the lines or contour in the plot, returned as a graphics array. Use dot notation to query and set properties of the graphics objects. For details, see Line Properties and Contour Properties. You can use name-value arguments to specify the appearance of
diagnostic data points corresponding to the first graphics object
|
Examples
More About
Tips
The data cursor displays the values of the selected plot point in a data tip (small text box located next to the data point). The data tip includes the x-axis and y-axis values for the selected point, along with the observation name or number.
References
[1] Neter, J., M. H. Kutner, C. J. Nachtsheim, and W. Wasserman. Applied Linear Statistical Models, Fourth Edition. Irwin, Chicago, 1996.