search for: numofdatapoints

Displaying 1 result from an estimated 1 matches for "numofdatapoints".

2005 Mar 16
1
returning NULL from .Call call
...#39;data' } catch(...) { std::cout << "Load failed (ANY REASON) - returning NULL" << std::endl; return NULL; } // operation successful, but the size of data can be nil if(data == NULL) return NULL; SEXP result = allocVector(INTSXP, numOfDataPoints); PROTECT(result); // copy data from 'data' into 'result' delete[] data; UNPROTECT(1); return result; } This function will nicely return a data array if no load problems occur and data is more than nil. If it is not the case I would be happy to receive a NULL...