Skip to content

Commit

Permalink
added an extra check that Lm isn't under-constrained
Browse files Browse the repository at this point in the history
  • Loading branch information
darrenjw committed Oct 30, 2024
1 parent 77c18e1 commit b815750
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ resolvers ++= Seq(

scalaVersion := "3.3.3"

crossScalaVersions := Seq("2.12.19", "2.13.13", "3.3.3")
crossScalaVersions := Seq("2.12.19", "2.13.14", "3.3.3")

ThisBuild / versionScheme := Some("strict")

Expand Down
1 change: 1 addition & 0 deletions src/main/scala/scalaglm/Lm.scala
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ case class Lm(y: DVD,
val X = if (addIntercept) DenseMatrix.horzcat(
DenseVector.ones[Double](Xmat.rows).toDenseMatrix.t, Xmat)
else Xmat
require(X.rows >= X.cols)

/**
* Column names (including intercept)
Expand Down

0 comments on commit b815750

Please sign in to comment.