CakePHP + Python's scipy/numpy/matolab/etc?

3 messages Options
Embed this post
Permalink
Josh-10

CakePHP + Python's scipy/numpy/matolab/etc?

Reply Threaded More More options
Print post
Permalink

Hello,

I've got a question about mixing languages in a project:

I am using Cake on an App and it is going quite well. However, I now
need to do some statistical analysis/curve fitting/advanced plotting/
matrix manipulation/object difference calc/etc. In retrospect, I
should have done this project in a python framework from the
beginning, but I like Cake so I stuck with it. Now I am looking to get
the functionality of scipy/numpy/matolab/etc APIs/modules. At this
point, how best should I integrate these? Would it be easiest to make
a bare bones API that returns the data/NLR formulas in perhaps a json
or xml format?  I was thinking of using a python framework such as
Django so as to be able to use its serializer and other tools. Any
suggestions? Has anyone had to integrate code libraries from other
languages in this way before?

Please let me know if I'm wrong about PHP and if I've over looked
libraries with functionality and stability that rival the python
libraries I mentioned.

Thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Dr. Loboto

Re: CakePHP + Python's scipy/numpy/matolab/etc?

Reply Threaded More More options
Print post
Permalink

PHP and Python code cannot be "integrated". You can call your Python
code through exec() and exchange data by text/xml/whatever files. Or
just send initial data as param and output result.

On Nov 2, 12:43 pm, Josh <[hidden email]> wrote:

> Hello,
>
> I've got a question about mixing languages in a project:
>
> I am using Cake on an App and it is going quite well. However, I now
> need to do some statistical analysis/curve fitting/advanced plotting/
> matrix manipulation/object difference calc/etc. In retrospect, I
> should have done this project in a python framework from the
> beginning, but I like Cake so I stuck with it. Now I am looking to get
> the functionality of scipy/numpy/matolab/etc APIs/modules. At this
> point, how best should I integrate these? Would it be easiest to make
> a bare bones API that returns the data/NLR formulas in perhaps a json
> or xml format?  I was thinking of using a python framework such as
> Django so as to be able to use its serializer and other tools. Any
> suggestions? Has anyone had to integrate code libraries from other
> languages in this way before?
>
> Please let me know if I'm wrong about PHP and if I've over looked
> libraries with functionality and stability that rival the python
> libraries I mentioned.
>
> Thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

jperras

Re: CakePHP + Python's scipy/numpy/matolab/etc?

Reply Threaded More More options
Print post
Permalink
In reply to this post by Josh-10

http://stackoverflow.com/questions/166944/calling-python-in-php
http://www.csh.rit.edu/~jon/projects/pip/

It's not the simplest thing, but it's doable.
-j.

On Nov 2, 1:43 am, Josh <[hidden email]> wrote:

> Hello,
>
> I've got a question about mixing languages in a project:
>
> I am using Cake on an App and it is going quite well. However, I now
> need to do some statistical analysis/curve fitting/advanced plotting/
> matrix manipulation/object difference calc/etc. In retrospect, I
> should have done this project in a python framework from the
> beginning, but I like Cake so I stuck with it. Now I am looking to get
> the functionality of scipy/numpy/matolab/etc APIs/modules. At this
> point, how best should I integrate these? Would it be easiest to make
> a bare bones API that returns the data/NLR formulas in perhaps a json
> or xml format?  I was thinking of using a python framework such as
> Django so as to be able to use its serializer and other tools. Any
> suggestions? Has anyone had to integrate code libraries from other
> languages in this way before?
>
> Please let me know if I'm wrong about PHP and if I've over looked
> libraries with functionality and stability that rival the python
> libraries I mentioned.
>
> Thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to [hidden email]
To unsubscribe from this group, send email to [hidden email]
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---