R and Python

alienyouth
alienyouth Global Mapper User
Greetings to the Global Mapper theme.

Please is there any plan to integrate the R or Python programming language in GM. I believe it will go a long way in improving the GM arsenal for data oriented applications.

Comments

  • bmg_bob
    bmg_bob Global Mapper Programmer
    Hello,

    Can you clarify what you mean by "integrate the R or Python programming language in GM"? What kind of functionality are you looking for?

    Cheers,
    Bob
  • JeffH@BMG
    JeffH@BMG Global Mapper Developer Trusted User
    Hi alienyouth,

    Global Mapper is a Windows program that exports a C API via its SDK (https://www.bluemarblegeo.com/products/global-mapper-sdk.php). I'm pretty sure that that can be consumed by Python, You'd be able to write Python programs to use GM as an analysis tool and possibly integrate with results obtained via Pyhton interfacing to some other service. Note that I've never tried it nor heard of anyone else who has. Is that what you're after?

    The flip side of that would be embedding a Python interpreter into Global Mapper, and having that implement functionality that GM can't do conveniently natively. Maybe that's what you're looking for.

    I can't speak to R's capabilities. With respect to Python, I'd probably start here for more understanding: https://docs.python.org/3/extending/index.html.

    Per Bob, a more concrete use case would be helpful.

    Best regards,

    ~Jeff
  • alienyouth
    alienyouth Global Mapper User
    Thanks for the quick response. 

    A scenario i always find myself when working with gridded datasets is that i need to be able to analyse years of daily rainfall grids; crop, extract, and compute statistics, then plot the results.

    I personally use R for these kind of analyses but it is weak in the data visualization & plotting department (in my opinion), so I'm left to shuffle between both softwares to get my job done.

    I'm aware that GM has scripting capabilities to automate some tasks but my question now is do i have to learn to script in GM or can it be possible for people like me who already know how to work with R or Python to have GM interface to seamlessly exchange data & results.

    QGIS has something of this sort but I've not really explored it cos i prefer GM.
  • alienyouth
    alienyouth Global Mapper User
    As a form of further clarification, is it possible for the GM experts to explain or refer me to how I can come up with the image below using GM alone. I computed the sum of 365 geotiff grids and output a single geotiff image (using R), then I finally plotted the result using GM. Most times I have to perform more complex statistical analyses which I already know how to do using R.


    Best Regards.