search for: testtxt

Displaying 3 results from an estimated 3 matches for "testtxt".

Did you mean: testext
2007 Dec 03
2
interaction with C++ code (PR#10487)
...extracttxt( char **txt, int *nchars) { std::ostringstream oss; oss << "abcdefghij"; const char *ltxt=oss.str().c_str(); for (int j=0;j<*nchars;j++) *txt[j]=static_cast<char>(ltxt[j]); } } # begin R code dyn.load("test.so") "testtxt" <- function() { nchars <- 80 txt <- .C("extracttxt" ,character(nchars) ,as.integer(nchars))[[1]] txt } a=testtxt() a[1:10] # typically the results are something like [1] "a" "b\033\xba\bfaul\030" "c...
2009 Jun 23
1
Accessing an object from the function in its .Data slot?
...tried to use the call stack, and this does seem to work: > setClass("abcd", representation(.Data="function", x="character")) > a = new("abcd", > .Data=function() str( get( as.character( sys.call()[[1]] ), pos=parent.frame() ) ), > x="testtxt") > a() Formal class 'abcd' [package ".GlobalEnv"] with 2 slots ..@ .Data:function (x) ..@ x : chr "testtxt" That is obviously a not-so-elegant hack, and I'm not sure it works under all circumstances as I'm not an expert on R's call system. I...
2007 Jan 26
3
Office 2007 saves files as read only on samba shares?
I've been running the same configuration for a couple of years now, and since I've upgraded to Office 2007, MS Word and MS Excel files save to my samba shares as -r-------- even when they are opened as being chmod 777. Files I create/edit using other editors or windows explorer are put onto the share with the correct permissions. My conf looks like this: [global] workgroup = WG