-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add documentation for methods #17
Conversation
# | ||
# @param [Symbol] as_a Specifies the form of output | ||
# | ||
# @return [Array, Hash] coefficients of the model |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this and some other methods it looks like, if as_a=:array
is specified, then a Daru::Vector
is returned, rather than an Array
... Is that an issue? (If it is, I think that it can be a separate pull request though)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're right it will need to be fixed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressed in #19
I read that Likelihood is a tool for summarizing the data’s evidence about unknown parameters. But here it doesn't take any input and returns a single value, so it's surprising me and I am not sure what its meant for. |
@lokeshh The log-likelihood is a function of the unknown parameters (such as the regression coefficients). The MLE (maximum likelihood estimation) algorithm aims to find values for the unknown parameters, at which the log-likelihood is maximized. I think here, It is useful, for example, if you fit two different models to the same data, and want to compare them. Then |
@@ -74,6 +105,24 @@ def fitted_mean_values | |||
@regression.fitted_mean_values | |||
end | |||
|
|||
# Returns for every data point obtained using the model |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think here is a typo. Do you mean "Returns the residual for (...)"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I updated it.
I think it can be merged now. I haven't changed the method names in this PR because it was for documentation purpose. For that I have this PR which also refactor some code #28 |
Addresses #4