# MathematicaStan

**URL:** <https://discourse.mc-stan.org/t/mathematicastan/92>\
**Category:** Developers\
**Created:** [October 4, 2016, 10:03am UTC](https://discourse.mc-stan.org/t/mathematicastan/92 "2016-10-04T10:03:17Z")\
**Posts on this page:** 17\
**Page:** 1

<div class="post-metadata">

**Author:** ![vincent-picaud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/vincent-picaud/32/24_2.png) [@vincent-picaud](https://discourse.mc-stan.org/u/vincent-picaud)\
**Post date:** [October 4, 2016, 10:03am UTC](https://discourse.mc-stan.org/t/mathematicastan/92/1 "2016-10-04T10:03:17Z")

</div>

Hi all,

After having met, Daniel, Eric and Michael in Paris at a Meetup (I hope everybody is going well :) ), here is some words concerning MathematicaStan, a Mathematica CmdStan wrapper.

The GitHub repo is still there: [https://github.com/vincent-picaud/MathematicaStan](https://github.com/vincent-picaud/MathematicaStan)

Even if some features like multiple instances of CmdStan for parallel sampling are missing, the interface is stable.

The only feedbacks I had are related to my post there [stackoverflow post](http://mathematica.stackexchange.com/questions/73997/computational-bayesian-analysis-in-mathematica-any-plans-to-develop-mcmc/126452#126452)

Regards,  
Vincent

---

<div class="post-metadata">

**Author:** ![syclik](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/syclik/32/6_2.png) [@syclik](https://discourse.mc-stan.org/u/syclik)\
**Post date:** [October 4, 2016, 11:29am UTC](https://discourse.mc-stan.org/t/mathematicastan/92/2 "2016-10-04T11:29:44Z")

</div>

Hi Vincent,

I’m really sorry: I meant to email you last week.

If you’re still willing, we can have MathematicaStan listed on the website, you added to the developers, and have the repo hosted at [GitHub.com/stan-dev](http://GitHub.com/stan-dev)

If you want to shift the repo, please add me as an admin on your repo. I can then transfer the repo to stan-dev.

Daniel

---

<div class="post-metadata">

**Author:** ![vincent-picaud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/vincent-picaud/32/24_2.png) [@vincent-picaud](https://discourse.mc-stan.org/u/vincent-picaud)\
**Post date:** [October 4, 2016, 1:05pm UTC](https://discourse.mc-stan.org/t/mathematicastan/92/3 "2016-10-04T13:05:08Z")

</div>

Hi Daniel,  
Please, do not worry about it, really… Time is running so fast for all of us.  
I added you as collaborator to the MathematicaStan repo, I hope I understood you well and it is what you need.  
Vincent

---

<div class="post-metadata">

**Author:** ![syclik](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/syclik/32/6_2.png) [@syclik](https://discourse.mc-stan.org/u/syclik)\
**Post date:** [October 4, 2016, 2:23pm UTC](https://discourse.mc-stan.org/t/mathematicastan/92/4 "2016-10-04T14:23:42Z")

</div>

Thanks!

I wasn’t right about giving me access – that used to work, but now it doesn’t. Can you try transferring to me? (syclik)

Once I have ownership, I can move it to stan-dev.

GitHub’s permissions have changed so much since we started with them.

---

<div class="post-metadata">

**Author:** ![vincent-picaud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/vincent-picaud/32/24_2.png) [@vincent-picaud](https://discourse.mc-stan.org/u/vincent-picaud)\
**Post date:** [October 4, 2016, 3:33pm UTC](https://discourse.mc-stan.org/t/mathematicastan/92/5 "2016-10-04T15:33:33Z")

</div>

Re Daniel,  
I have done a mirror copy of the MathematicaStan repo (for my usage) and given you the ownership of the GitHub repo.  
I hope that you can move it now.  
Thanks,  
Vincent

---

<div class="post-metadata">

**Author:** ![syclik](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/syclik/32/6_2.png) [@syclik](https://discourse.mc-stan.org/u/syclik)\
**Post date:** [October 4, 2016, 5:43pm UTC](https://discourse.mc-stan.org/t/mathematicastan/92/6 "2016-10-04T17:43:41Z")

</div>

Hi Vincent,

It’s moved! [https://github.com/stan-dev/MathematicaStan](https://github.com/stan-dev/MathematicaStan)

And you have admin access on that repo.

Daniel

---

<div class="post-metadata">

**Author:** ![vincent-picaud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/vincent-picaud/32/24_2.png) [@vincent-picaud](https://discourse.mc-stan.org/u/vincent-picaud)\
**Post date:** [October 4, 2016, 7:27pm UTC](https://discourse.mc-stan.org/t/mathematicastan/92/7 "2016-10-04T19:27:18Z")

</div>

Hi Daniel,  
Thank you. I will test it as soon as I have new commits.  
Vincent

---

<div class="post-metadata">

**Author:** ![vincent-picaud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/vincent-picaud/32/24_2.png) [@vincent-picaud](https://discourse.mc-stan.org/u/vincent-picaud)\
**Post date:** [October 15, 2016, 9:19am UTC](https://discourse.mc-stan.org/t/mathematicastan/92/8 "2016-10-15T09:19:27Z")

</div>

Some good news from MathematicaStan.

Thanks to Jeff Patterson contribution, we have fixed some minor path problems and have confirmation that it works under Windows:

[https://github.com/stan-dev/MathematicaStan/issues/1](https://github.com/stan-dev/MathematicaStan/issues/1)

I am happy with that as all the developments have been done under Linux and I have no access to Windows.

Using the MathematicaStan package, Jeff also sent me very interesting notebooks that reproduce results from:  
[http://www.sanjogmisra.com/blog/stan/](http://www.sanjogmisra.com/blog/stan/)  
[http://mc-stan.org/documentation/case-studies/hierarchical\_2pl.html](http://mc-stan.org/documentation/case-studies/hierarchical_2pl.html)

I will ask him permission to upload them and invite him to continue our discussion here, so that we can befenit from your expertise.

@Daniel, now that we have confirmation that the package works under Windows, do you agree to add a link in the mc-stan site? I mean, I think it is a good way to inform others that this Mathematica wrapper exists.

Vincent

---

<div class="post-metadata">

**Author:** ![Bob\_Carpenter](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/bob_carpenter/32/9230_2.png) [@Bob\_Carpenter](https://discourse.mc-stan.org/u/Bob_Carpenter)\
**Post date:** [October 15, 2016, 7:02pm UTC](https://discourse.mc-stan.org/t/mathematicastan/92/9 "2016-10-15T19:02:20Z")

</div>

…

Great to hear this is almost ready to go.

> @Daniel, now that we have confirmation that the package works under Windows, do you agree to add a link in the mc-stan site? I mean, I think it is a good way to inform others that this Mathematica wrapper exists.

Yes, absolutely. And we’ll email the users list and  
put up a post on Andrew’s blog when the web site’s updated  
and ready to go.

For web site, we’ll put a link here:

[Redirecting…](http://mc-stan.org/interfaces/)

and then need a page similar to the one for MATLAB:

[Redirecting…](http://mc-stan.org/interfaces/matlab-stan.html)

If you give me the information, I can write it, or you can  
just make a pull request on our web site repo. Its wiki has  
instructions on how to run all the Jekyll locally.

We’d then also like to add you to our team page if  
that’s OK with you:

[Redirecting…](http://mc-stan.org/team/)

For that, we need a name and GitHub handle, and optionally:

- square photo that’ll look OK cropped round — the one you’re  
using here would work just fine
- affiliation
- home page
- email
- twitter handle
- linked in profile

And if you have some case study replications, we can also list them  
here as we did with the RStanArm translation of my hierarchical modeling  
case study:

[http://mc-stan.org/documentation/case-studies.html](http://mc-stan.org/documentation/case-studies.html)

- Bob

---

<div class="post-metadata">

**Author:** ![vincent-picaud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/vincent-picaud/32/24_2.png) [@vincent-picaud](https://discourse.mc-stan.org/u/vincent-picaud)\
**Post date:** [October 17, 2016, 9:23am UTC](https://discourse.mc-stan.org/t/mathematicastan/92/10 "2016-10-17T09:23:35Z")

</div>

Hi Bob,

Thank you for your answer,

> [@Bob\_Carpenter](#):
>
> If you give me the information, I can write it, or you can  
> just make a pull request on our website repo. Its wiki has  
> instructions on how to run all the Jekyll locally.

If you do not mind, it would be nice to proceed as you suggest because I have never used Jekyll.  
For the moment MathematicaStan does not have wiki pages, hence the only fields are:

1/ Download and Get Started: [GitHub - stan-dev/MathematicaStan: A Mathematica package to interact with CmdStan](https://github.com/stan-dev/MathematicaStan)  
2/ Documentation: the [README.org](http://README.org) file of the repo  
3/ Licence: GPL-3.0

> [@Bob\_Carpenter](#):
>
> We’d then also like to add you to our team page if  
> that’s OK with you:
> 
> [Redirecting…](http://mc-stan.org/team/)
> 
> For that, we need a name and GitHub handle, and optionally:
> 
> square photo that’ll look OK cropped round — the one you’re  
> using here would work just fine  
> affiliation  
> home page  
> email  
> twitter handle  
> linked in profile

It is ok and a pleasure to be added to the team:

photo: you can use the one I have here.  
affiliation: CEA, France  
home page: none  
email: [picaud.vincent@gmail.com](mailto:picaud.vincent@gmail.com)  
twitter handle: [https://twitter.com/PicaudV](https://twitter.com/PicaudV)  
linked in profile: [https://www.linkedin.com/in/vincent-picaud-a5087275](https://www.linkedin.com/in/vincent-picaud-a5087275)

> [@Bob\_Carpenter](#):
>
> And if you have some case study replications, we can also list them  
> here as we did with the RStanArm translation of my hierarchical modeling  
> case study:

For the moment these Mathematica notebooks, from Jeff Patterson, demonstrate how to:

1/ how to call R code from Mathematica (using Mathematica official RLink tool [Introduction to RLink—Wolfram Language Documentation](https://reference.wolfram.com/language/RLink/tutorial/Introduction.html)).

2/ extends the MathematicaStan **RDumpExport[]** function to support the RObject structure returned by the Mathematica official function **REvaluate[]**

There is still some work to get a smooth and portable (Linux&Window) integration of this, but having access in a coherent way to **R** & **Stan** from Mathematica is motivating.

Vincent

---

<div class="post-metadata">

**Author:** ![Bob\_Carpenter](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/bob_carpenter/32/9230_2.png) [@Bob\_Carpenter](https://discourse.mc-stan.org/u/Bob_Carpenter)\
**Post date:** [October 19, 2016, 12:45am UTC](https://discourse.mc-stan.org/t/mathematicastan/92/11 "2016-10-19T00:45:07Z")

</div>

OK, added MathematicaStan to our interfaces and  
you to our dev list on the web site. The web pages are  
just another GitHub repo. It’s a very convenient way to  
set up a server—GitHub does the serving and merges to  
master update the generated site.

I scheduled a blog post announcing MathematicaStan on Andrew’s  
blog for 3 PM New York time tomorrow (Wednesday 19 November).

Thanks again!

- Bob

---

<div class="post-metadata">

**Author:** ![vincent-picaud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/vincent-picaud/32/24_2.png) [@vincent-picaud](https://discourse.mc-stan.org/u/vincent-picaud)\
**Post date:** [October 19, 2016, 5:41am UTC](https://discourse.mc-stan.org/t/mathematicastan/92/12 "2016-10-19T05:41:54Z")

</div>

Great!  
I am happy to contribute to Stan, I really like this software.  
Many thanks too.  
Vincent

---

<div class="post-metadata">

**Author:** ![Bob\_Carpenter](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/bob_carpenter/32/9230_2.png) [@Bob\_Carpenter](https://discourse.mc-stan.org/u/Bob_Carpenter)\
**Post date:** [October 19, 2016, 5:54am UTC](https://discourse.mc-stan.org/t/mathematicastan/92/13 "2016-10-19T05:54:03Z")

</div>

Sounds like we could use your help down at the Math library  
C++ level. We’ve pulled it all out into its own repo in  
GitHub.

- Bob

---

<div class="post-metadata">

**Author:** ![vincent-picaud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/vincent-picaud/32/24_2.png) [@vincent-picaud](https://discourse.mc-stan.org/u/vincent-picaud)\
**Post date:** [October 19, 2016, 5:57am UTC](https://discourse.mc-stan.org/t/mathematicastan/92/14 "2016-10-19T05:57:47Z")

</div>

I hope I will be able to. I still have a lot to learn about Stan code design and organization in order to do right contributions.  
Vincent

---

<div class="post-metadata">

**Author:** ![syclik](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/syclik/32/6_2.png) [@syclik](https://discourse.mc-stan.org/u/syclik)\
**Post date:** [October 20, 2016, 12:35am UTC](https://discourse.mc-stan.org/t/mathematicastan/92/15 "2016-10-20T00:35:08Z")

</div>

Thanks for getting it up on the website, @Bob_Carpenter.

@vincent-picaud, we would love the help! If anything is confusing, please let us know and we’ll try to explain.

---

<div class="post-metadata">

**Author:** ![vincent-picaud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/vincent-picaud/32/24_2.png) [@vincent-picaud](https://discourse.mc-stan.org/u/vincent-picaud)\
**Post date:** [October 20, 2016, 2:35pm UTC](https://discourse.mc-stan.org/t/mathematicastan/92/16 "2016-10-20T14:35:22Z")

</div>

Some MathematicaStan news

I just have done a merge in the master branch

- Complete refactoring of option management  
The previous one was bugged and did not respect the option hierarchy

- Parallel sampling is now possible (under Linux)  
TODO: the windows version

- Doc improvement + notebook examples update

Vincent

---

<div class="post-metadata">

**Author:** ![vincent-picaud](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/vincent-picaud/32/24_2.png) [@vincent-picaud](https://discourse.mc-stan.org/u/vincent-picaud)\
**Post date:** [February 24, 2017, 9:13pm UTC](https://discourse.mc-stan.org/t/mathematicastan/92/17 "2017-02-24T21:13:09Z")

</div>

Some news from MathematicaStan.

I should have more free time in April, I have planned to write MathematicaStan V2.

The current implementation is compatible with Mathematica V8.0 (a quite old version).

MathematicaStan V2 will benefit from functionalities of more recent Mathematica versions (V10 or the latest V11).

Vincent
