[ 
https://issues.apache.org/jira/browse/SPARK-4907?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14253978#comment-14253978
 ] 

Apache Spark commented on SPARK-4907:
-------------------------------------

User 'dbtsai' has created a pull request for this issue:
https://github.com/apache/spark/pull/3746

> Inconsistent loss and gradient in LeastSquaresGradient compared with R
> ----------------------------------------------------------------------
>
>                 Key: SPARK-4907
>                 URL: https://issues.apache.org/jira/browse/SPARK-4907
>             Project: Spark
>          Issue Type: Bug
>          Components: MLlib
>            Reporter: DB Tsai
>
> In most of the academic paper and algorithm implementations, people use L = 
> 1/2n ||A weights-y||^2 instead of L = 1/n ||A weights-y||^2 for least-squared 
> loss. See Eq. (1) in http://web.stanford.edu/~hastie/Papers/glmnet.pdf
> Since MLlib uses different convention, this will result different residuals 
> and all the stats properties will be different from GLMNET package in R. The 
> model coefficients will be still the same under this change. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to