505 questions
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
Best practices
0
votes
4
replies
33
views
How to efficiently extract variables from a python function into an r dataframe using dplyr?
I have a dataframe called Profile_1_2 of data that is formatted like this:
Profile_number
chl_z
Cphyto_z
1
0.2
10
1
0.6
100
2
0.1
20
2
0.5
90
Profile_number denotes a group, each profile contains 200 ...
0
votes
0
answers
63
views
Integrating R functions in Python AWS Bedrock agents
I have the following Python code and I was just curious how I can use the rpy2 package to import some R functions such that Bedrocks Agent() can have access to them. (I know I could just write a Sys....
1
vote
1
answer
91
views
Setting app authentication using LDAP in R shiny (reticulate/ldap3) An dI can't perform search for user in the directory
I've been developing an app in R Shiny and deployed it locally at my company. I'm trying to set up an authentication process using an LDAP server. I managed to connect to the LDAP server using an ...
1
vote
1
answer
125
views
R Reticulate does work with for loop but not purrr::map2
I want to remove passwords from several Excel files, so I specified a data frame with paths and passwords and then added some python code running with reticulate.
When I pass that function to a for ...
2
votes
0
answers
93
views
Run reticulate::py_require() once on package installation
We have an internal python library that we want to build an R wrapper for. The python package only needs to be installed once and not every time. The documentation says to use py_require() over ...
1
vote
0
answers
86
views
R with Reticulate crashes on MacMini and not on Windows
I want to use the Python versions of TabPFN and AutoGluon via the reticulate package in R. When I run the code on my laptop (Windows), everything works fine. However, as soon as I run the same code on ...
0
votes
0
answers
42
views
Import of arcpy in R via reticulate fails with DLL load error
I've just installed ArcGIS Pro 3.5 on my Windows PC. I would like to use the arcpy Python library in R via the reticulate package, as I have done this successfully in the past.
For the sake of getting ...
2
votes
1
answer
178
views
reticulate cannot bind to Python: "was not built with a shared library" even after setting environment
I'm using R with the reticulate package to run Python code. When I try to load reticulate, I get the following error:
Error: '/usr/bin/python3.10' was not built with a shared library. reticulate can ...
2
votes
1
answer
145
views
R reticulate to import sentence_transformers: "encode() argument 'encoding' must be str, not int"
I want to import a module with
library(reticulate)
sentence_transformers <- import("sentence_transformers")
but get this error
Error in py_module_import(module, convert = convert) :
...
0
votes
2
answers
60
views
Reticulate not displaying pandas dataframes correctly
I just updated conda and Rstudio and now dataframes will not show up correctly in RStudio. R dataframes show up correctly but not pandas (image attached). The pandas dataframes are correctly displayed ...
0
votes
0
answers
91
views
How to debug Python functions in Rstudio?
I have Python chunks in an Rmd file in Rstudio that I would like to debug.
I am using ipdb but when it gets to the breakpoint in the function it doesn't open a separate terminal as I was expecting ...
1
vote
1
answer
295
views
Reticulate with pywin32, a dependency of xlwings, not found when sourcing python script from R [duplicate]
Overview
I have a python script opens an excel workbook, makes some changes, then saves it. This is just one step in a series of excel processing operations, most of which are written in R. My end ...
1
vote
0
answers
67
views
Issue with reticulate::py_module_available("rdkit") returning TRUE in RStudio Console but FALSE in Shiny Server.R
I'm encountering strange behavior using the reticulate package in R. When I run the following in the RStudio console:
reticulate::py_module_available("rdkit")
It returns TRUE, but when I ...
1
vote
1
answer
61
views
Why is reticulate::py_available() FALSE until I I run reticulate::py_run_string("")?
Why do I first have to submit something through reticulate::py_run_string() for reticulate::py_available() to return TRUE?
I ran the below set of calls through a clean R session:
> packageVersion(&...
1
vote
1
answer
58
views
Installing Databricks Connect fails because "LINK : fatal error LNK1181: cannot open input file 'R.lib'"
I am trying to set up database access to connect to my company's Databricks install, so I have been following the instructions here:
https://docs.databricks.com/en/dev-tools/databricks-connect/r/index....