scicloj / clojisr

Clojure speaks statistics - a bridge between Clojure to R
https://scicloj.github.io/clojisr/
Eclipse Public License 2.0
153 stars 10 forks source link

more lazy definition of primitive R functions #95

Open behrica opened 6 months ago

behrica commented 6 months ago

These type of def https://github.com/scicloj/clojisr/blob/f42566ff6a683ca764d238f42c4f0e0f49550abf/src/clojisr/v1/r.clj#L127

make R to get initialised on loading the ns which is "bad practice". Ideally a ns loading should "do nothing".

It might be possible to change all of them to a function:

(defn r== [e1 e2] ((clojisr.v1.r/r "`==`") e1 e2)) 
behrica commented 6 months ago

Needed to be solved to get cljdoc on CI server working: see #94

behrica commented 6 months ago

I will give this a try and make a PR

behrica commented 6 months ago

For the simple functions "r_xx" it looks good. Not sure I manage the bra macros

behrica commented 6 months ago

PR #99 has been started

behrica commented 6 months ago

PR #99 is ready for review