Skip to content

Commit 48bd551

Browse files
authored
Add Term, EvalFactor to import in order for code to run
1 parent a5b54c2 commit 48bd551

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

doc/formulas.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,12 +58,13 @@ To make this more concrete, here's how you could manually construct
5858
the same objects that Patsy will construct if given the above
5959
formula::
6060

61-
from patsy import ModelDesc
61+
from patsy import ModelDesc, Term, EvalFactor
6262
ModelDesc([Term([EvalFactor("y")])],
6363
[Term([]),
6464
Term([EvalFactor("a")]),
6565
Term([EvalFactor("a"), EvalFactor("b")]),
66-
Term([EvalFactor("np.log(x)")])])
66+
Term([EvalFactor("np.log(x)")])
67+
])
6768

6869
Compare to what you get from parsing the above formula::
6970

0 commit comments

Comments
 (0)