similar to: How to pass an array to a javascript function.

Displaying 20 results from an estimated 500 matches similar to: "How to pass an array to a javascript function."

2007 Apr 27
1
Example of mcmcsamp() failing with lmer() output
Hi, I would appreciate help with the following model <<1>>= gunload <- read.table(hh('datasets/gunload.dat'), header = T) gunload$method <- factor(gunload$method, labels = c('new', 'old')) gunload$physique <- factor(gunload$group, labels = c('slight', 'average', 'heavy')) gunload$team9 <- factor(rep(1:9, each = 2)) @ This
2010 Sep 16
1
Possible bug or annoyance with library.dynam.unload()
Hello, I have a package with a namespace. Because I use Roxygen that overwrites the NAMESPACE file each time it is run, I use a R/zzz.R file with an .onLoad() and .onUnload() functions to take care of loading and unloading my shared library. The problem: if I load my library from a local directory, then the unloading of the package fails, e.g: # loads fine >library(Foo,
2006 Feb 08
2
Using .onUnload() to unload compiled code
If one wants to unload compiled code for a package containing a namespace, my understanding is that .onUnload() should be used, with a call to library.dynam.unload(). This is used in e.g., the stats and methods packages, but it appears to me that the compiled code is not being unloaded when the package is detached(). Am I misunderstanding something? Best, Jim > search() [1]
2012 Jul 24
1
Using .onUnload to unload DLLs
I've noticed that many of the "base" R packages have an .onUnload() function which automatically unloads compiled shared libraries with library.dynam.unload(). For example: > stats:::.onUnload function (libpath) library.dynam.unload("stats", libpath) <bytecode: 0x1033b9c30> <environment: namespace:stats> I've noticed that many other packages don't
2010 Nov 12
1
unloading compiled code.
I have a package that I'm developing that I need to unload the library. Long story short I figured out that the leaving the compiled code loaded lead to a segmentation fault, but unloading the code will fix it. I've read the documentation and it appears that there are several ways to do this? What is the popper accepted current standard for unloading compiled code? The options as I
2008 Apr 24
4
Scriptaculous Help (page exit effects)
I was wondering if it was possible in Prototype/Scriptaculous to run an effect when a link is clicked, then go to that page, or if it was possible to have an effect run when the page unloads. I have tried <body onunload="new Effect.Fade("whatever");> and some prototype page exit events, could get a alert("") function to work, but not the effects. Any ideas?
2016 Mar 25
1
library.dynam.unload
The survival package has a firstlib.R file that I had forgotton and just reviewed. After deleting several bits which had a use 10 years ago during my Splus to R transition, the only thing remaining is .onUnload <- function(libpath) library.dynam.unload("survival", libpath) Does this bit of code still serve a purpose? Can I toss it? Terry T.
2009 Mar 31
4
what is the preferred method to create a package local variable?
for the moment, I'm using: .onAttach <- function(libname, pkgname) { .bbg.db.conn <<- dbConnect(dbDriver("PostgreSQL"), user="blah","blah") } .onUnload <- function(libpath) { dbDisconnect(.bbg.db.conn) } which results in a hidden global variable in the global environment. I would prefer to make the assignment only in the package namespace.
2007 Nov 28
0
7 commits - configure.ac libswfdec/swfdec_movie.c libswfdec/swfdec_movie.h libswfdec/swfdec_sprite_movie.c test/trace
configure.ac | 7 ++- libswfdec/swfdec_movie.c | 57 ++++++++++----------------- libswfdec/swfdec_movie.h | 3 - libswfdec/swfdec_sprite_movie.c | 4 - test/trace/Makefile.am | 18 ++++++++ test/trace/remove-child-onUnload-5.swf |binary
2011 Mar 11
1
hook for when R quits
Hi, Is there any way that a package can listen for when R quits? The Qt stuff is hooking into platform-specific event loops and when those die unexpectedly (from the perspective of Qt), it aborts, causing an annoying error dialog. If we could catch when R is killed, we could cleanup, like we do with .onUnload. Thanks, Michael [[alternative HTML version deleted]]
2004 Apr 28
2
Rtemp directories accumulating over time
Hola! There is a nuisance that the number of directories with name starting Rtmp (and always empty) in my temp directory is increasing over time. I put the following in my .Rprofile: tmp0001 <- tempdir() setHook( packageEvent("base","onUnload"), function(...) unlink( tmp0001, recursive=TRUE) ) which solves part of the problem, but not all. So there are also
2010 Feb 25
0
nested design
This is a nested design where team is nested in group. Method is fixed, while team and group are random. Is this the correct R code for this? gunload.aov <- aov(rounds ~ method+group + Error((team %in% group)/method),data=gunload, qr=T) -- View this message in context: http://n4.nabble.com/nested-design-tp1569449p1569449.html Sent from the R help mailing list archive at Nabble.com.
2017 Sep 28
1
rgl crash on windows 7
I have a co-worker who has installed R 3.4.2 on Windows 7. When this person tries to load the rgl package with library(rgl) A dialog box appears with the message: R for windows gui frontend has stopped working I suspect a conflict problem with a dll, but I'm not sure how to identify if this is the problem since R is crashing immediately. Interestingly, when we start R and do NOT load rgl,
2005 Jun 28
1
Thomas script.aculo.us (important bug and add ons)
Sorry. Posted from wrong email originally. Moderator, please ignore other post. Thx. To Thomas Fuchs, First of all, thanks for your amazing scripts on script.aculo.us. You''ve got quite some talent. I knew I was in for a treat when I read your goals (mainly about simplicity). My goals exactly. Keep it simple is great when you''re trying to integrate 100 different things. I wrote
2006 Jul 10
4
Detecting the close of a browser
Hi, I noticed that www.meebo.com has the ability that when you close the browser during a session, it prompts you , are you sure you want to close? How does it do this? I would like to use such an ability , so that if the user preempts a close on the browser, I can kill all threads I have running for that user. Thanks -- Posted via http://www.ruby-forum.com/.
2011 Jan 26
1
Problem with "setMethod" in R package
Dear all, My apologies for re-posting this question, but I have not found any solution to my problem so far. I also think that my post may have been overseen due to the posting time and high traffic on this list. I experience a problem in implementing a S4 class in a package and would appreciate your help in this matter. The class is implemented using Rcpp, which works well. I then extend
2007 Dec 18
2
Changes to 'refs/tags/0.5.5'
Tag '0.5.5' created by Benjamin Otte <otte at gnome.org> at 2007-12-17 20:20 -0800 release 0.5.5 ("cps") -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux) iD8DBQBHZtodvMv5VCdLq8QRAvTmAKDtEvlvtLBIj5nu8GE6ECGjh8lCGQCgyiAN Dkfb85qxYlfTKKJC6qYH/sU= =VWgB -----END PGP SIGNATURE----- Changes since 0.5.4: Andreas Henriksson (1): make
2007 Nov 28
0
59 commits - libswfdec-gtk/swfdec_gtk_widget.c libswfdec/swfdec_as_object.c libswfdec/swfdec_as_object.h libswfdec/swfdec_button.c libswfdec/swfdec_button.h libswfdec/swfdec_button_movie.c libswfdec/swfdec_button_movie.h libswfdec/swfdec_event.c
libswfdec-gtk/swfdec_gtk_widget.c | 19 libswfdec/swfdec_as_object.c | 56 +- libswfdec/swfdec_as_object.h | 4 libswfdec/swfdec_button.c | 228 +++++++++ libswfdec/swfdec_button.h | 10 libswfdec/swfdec_button_movie.c | 382
2007 Jan 16
2
on.exit called on loading ?
I just found out that an .onLoad() function such as this stylized one (where I just renamed some identifiers) .onLoad <- function(lib, pkg) { require(zoo, quiet=TRUE, warn.conflicts=FALSE) library.dynam("foolib", pkg, lib ) if (.Platform$OS.type != "windows") { initSomeServices() } if (.Platform$OS.type != "windows") {
2005 Nov 11
0
(kind of OT) Equivalent to onunload or onbeforeunload in Safari?
I realize this isn''t specifically a Rails question, but I figure others here will have encountered it. I have a client that wants form data to be saved when leaving a page. This could include leaving a page by following a link, closing a window, or pressing the back or forwards buttons. So ... I do some research, and found this Web page: