EVOLUTION-MANAGER
Edit File: fittedModel.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>R: quantmod Fitted Objects</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <link rel="stylesheet" type="text/css" href="R.css" /> </head><body> <table width="100%" summary="page for fittedModel {quantmod}"><tr><td>fittedModel {quantmod}</td><td style="text-align: right;">R Documentation</td></tr></table> <h2> quantmod Fitted Objects </h2> <h3>Description</h3> <p>Extract and replace fitted models from <code>quantmod</code> objects built with <code>buildModel</code>. All objects fitted through methods specified in <code>buildModel</code> calls can be extracted for further analysis. </p> <h3>Usage</h3> <pre> fittedModel(object) ## S3 method for class 'quantmod' formula(x, ...) ## S3 method for class 'quantmod' plot(x, ...) ## S3 method for class 'quantmod' coefficients(object, ...) ## S3 method for class 'quantmod' coef(object, ...) ## S3 method for class 'quantmod' residuals(object, ...) ## S3 method for class 'quantmod' resid(object, ...) ## S3 method for class 'quantmod' fitted.values(object, ...) ## S3 method for class 'quantmod' fitted(object, ...) ## S3 method for class 'quantmod' anova(object, ...) ## S3 method for class 'quantmod' logLik(object, ...) ## S3 method for class 'quantmod' vcov(object, ...) </pre> <h3>Arguments</h3> <table summary="R argblock"> <tr valign="top"><td><code>object</code></td> <td> <p> a <code>quantmod</code> object </p> </td></tr> <tr valign="top"><td><code>x</code></td> <td> <p> a suitable object </p> </td></tr> <tr valign="top"><td><code>...</code></td> <td> <p> additional arguments </p> </td></tr> </table> <h3>Details</h3> <p>Most often used to extract the final fitted object of the modelling process, usually for further analysis with tools outside the <span class="pkg">quantmod</span> package. </p> <p>Most common methods to apply to fitted objects are available to the parent <code>quantmod</code> object. At present, one can call directly the following S3 methods on a built model as if calling directly on the fitted object. See *Usage* section. </p> <p>It is also <em>possible</em> to add a fitted model to an object. This may be of value when applying heuristic rule sets for trading approaches, or when fine tuning already fit models by hand. </p> <h3>Value</h3> <p>Returns an object matching that returned by a call to the method specified in <code>buildModel</code>. </p> <h3>Note</h3> <p>The replacement function <code>fittedModel<-</code> is highly experimental, and may or may not continue into further releases. </p> <p>The fitted model added <em>must</em> use the same names as appear in the <code>quantmod</code> object's dataset. </p> <h3>Author(s)</h3> <p> Jeffrey A. Ryan </p> <h3>See Also</h3> <p><code><a href="quantmod-package.html">quantmod</a></code>,<code><a href="buildModel.html">buildModel</a></code> </p> <h3>Examples</h3> <pre> ## Not run: x <- specifyModel(Next(OpCl(DIA)) ~ OpCl(VIX)) x.lm <- buildModel(x,method='lm',training.per=c('2001-01-01','2001-04-01')) fittedModel(x.lm) coef(fittedModel(x.lm)) coef(x.lm) # same vcov(fittedModel(x.lm)) vcov(x.lm) # same ## End(Not run) </pre> <hr /><div style="text-align: center;">[Package <em>quantmod</em> version 0.4.20 <a href="00Index.html">Index</a>]</div> </body></html>