search for: ptr_r_readconsol

Displaying 8 results from an estimated 8 matches for "ptr_r_readconsol".

Did you mean: ptr_r_readconsole
2014 Oct 27
0
Calling the original function after tweaking arguments is an incorrect use of the R-API?
...trying to create a small extension for R here for embedding the current time on the R prompt:https://github.com/musically-ut/extPrompt Things seem to be working overall, but R CMD check . raised a warning: File '[truncated]..Rcheck/extPrompt/libs/extPrompt.so?: Found non-API call > to R: ?ptr_R_ReadConsole? Compiled code should not call non-API entry points in R. The concerned file is this: https://github.com/musically-ut/extPrompt/blob/master/src/extPrompt.c and occurs on line 38, I think. void extPrompt() { > // Initialize the plugin by replacing the R_ReadConsole function > old_...
2014 Oct 12
1
Is this an incorrect use of the R-API?
...o create a small extension for R here for embedding the current time on the R prompt: https://github.com/musically-ut/extPrompt Things seem to be working overall, but `R CMD check .` raised a warning: > File '[truncated]..Rcheck/extPrompt/libs/extPrompt.so?: > Found non-API call to R: ?ptr_R_ReadConsole? > > Compiled code should not call non-API entry points in R. The concerned file is this: https://github.com/musically-ut/extPrompt/blob/master/src/extPrompt.c and occurs on line 38, I think [1]. I am trying to make the R_ReadConsole API call. However, since a different plugin (like mine)...
2009 Sep 03
1
Running an expression 1MN times using embedded R
...bedded.h> #include <R_ext/Boolean.h> #include <R_ext/Parse.h> #include <R_ext/Rdynload.h> const int i___ = 1; #define is_bigendian() ( (*(char*)&i___) == 0 ) extern void (*ptr_R_ShowMessage)(const char *); extern void (*ptr_R_WriteConsole)(const char *, int); extern int (*ptr_R_ReadConsole)(char *, unsigned char *, int, int); extern void (*ptr_R_WriteConsoleEx)(const char *, int , int ); SEXP rh_status(SEXP); static uint8_t SET_STATUS = 0x02; static R_CallMethodDef callMethods [] = { {"rh_status",(DL_FUNC)&rh_status,1}, {NULL, NULL, 0} }; uint32_t reverseUInt (...
2011 Jun 16
4
Controlling stdin and stdout in an embedded R instance
...ividually send native R commands to an embedded console and then consume the output of these commands. Specifically, I cannot send a set of commands to the embedded console and then consume all of the output after the execution completes. I have unsuccessfully attempted to assign values to the ptr_R_ReadConsole and ptr_R_WriteConsole function pointers defined in Rinterface.h but do not know if this is a valid approach. I am working in Ubuntu 10.04 and thus the Windows example at the following address is not applicable. http://cran.r-project.org/doc/manuals/R-exts.html#Calling-R_002edll-directly Does...
2008 Apr 29
2
Calling R from C - part way there but need a push!
...code from a file of my own", "set value of x", "make a call and read the values back into my C program"? Help is much appreciated. Regards, Max (1) The most likely include file is Rinterface.h and within that the most likely candidates seem to be: extern int (*ptr_R_ReadConsole)(const char *, unsigned char *, int, int); extern void (*ptr_R_WriteConsole)(const char *, int); extern void (*ptr_R_WriteConsoleEx)(const char *, int, int); but it turns out that they assume that R is running the terminal and these are requests to R to display or read from R's console....
2004 Jul 16
1
tkStartGUI fails under RW1091 (PR#7101)
> library(tcltk) > tkStartGUI() Error in .C("RTcl_ActivateConsole", PACKAGE = "tcltk") : C function name not in DLL for package tcltk > version _ platform i386-pc-mingw32 arch i386 os mingw32 system i386, mingw32 status major 1 minor 9.1 year 2004
2010 Jul 21
1
Plot window does not update in embedded code
...(int ac, char **av); /* in ../unix/system.c */ extern int R_running_as_main_program; /* in ../unix/system.c */ } int main(int ac, char **av) { R_running_as_main_program = 1; Rf_initialize_R(ac, av); ptr_R_WriteConsoleEx = &R_WriteConsoleEx; ptr_R_WriteConsole = &R_WriteConsole; ptr_R_ReadConsole = &R_ReadConsole; R_Outputfile = NULL; R_Consolefile = NULL; Rf_mainloop(); /* does not return */ return 0; }
2010 May 06
1
R on kdeedu-svn library problem
...kdeedu/cantor/src/backends/R/rserver/rcallbacks.cpp:45: undefined reference to `ptr_R_ShowMessage' $SOURCES/kdeedu/cantor/src/backends/R/rserver/rcallbacks.cpp:46: undefined reference to `ptr_R_Busy' $SOURCES/kdeedu/cantor/src/backends/R/rserver/rcallbacks.cpp:47: undefined reference to `ptr_R_ReadConsole' $SOURCES/kdeedu/cantor/src/backends/R/rserver/rcallbacks.cpp:48: undefined reference to `ptr_R_ShowFiles' collect2: ld returned 1 exit status ------------------------------- help would be appreciated. bvol