How to integrate a python in Basic Macro

Hello,
I’m currently working on a project which consists of extracting data from various files to put them in a single file in order to create visual graphs (bar chart,Map,etc) that I must insert in a doc file (Writer )

For the first part of the project ( extraction of data from different files to a single file) , I created a Basic Macro
To create the visual graphs and to insert them in a Writer file, I would like to use Python.
I would like to know if it’s possible to combine python and my Basic. If it is what are the best resources in order to learn how to do it

Thank you for your help

Yes you can call python from Basic and vice versa…( search for »scriptprovider« here in this forum to find a lot of Examples) … but IMHO you should simply rewrite the first part in python!

1 Like

Thanks for the answer. In my knowlegde python requires to install libraries (pandas,etc) to easily work with data But my macro should be working on any computer of the company(and outside) who has LibreOffice without the need of installing additionnal . Is it still possible?

not necessarily, most things can be done without »third-party modules«
Especially if you have already been able to do the first part successfully with Basic

…this task looks like you should use third-party matplotlib?!
.

Yes for the visuals.And I was thinking about turning them into Panda dataframe structure before

you know actually your Data … I dont!