Declare a variable in R and use in python file

I want to read a python file in R and I am using reticulate package for that.
I have data <- readLAS("TestSite2-4.las") where I am reading a las file and in my python code, I want to read this file: inFile = laspy.file.File("TestSite2-4.las", mode="r")

How do I declare, say, the file name string in R and then when I read source_python("") it takes this variable as file name in inFile?

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.