Hi Louis,
You could try this:
# find the index of the maximum value in each row of _data_, #
disregarding the last column classified <-
apply(data[,-(nclass+1)],1,which.max)
## or, if the maximum may be repeated:
classified <- apply(data[,-(nclass+1)], 1, FUN = function(x) which(x ==
max(x)))
#
Hi Tom,
Try this:
> G <- "Number: %s"
> sprintf(G, toString(A))
[1] "Number: 3, 4, 5"
Cheers Joe
Joe Crombie
Biosecurity and Information Sciences
Bureau of Rural Science
Canberra Australia
p: +61 2 6272 5906
e: [EMAIL PROTECTED]
-Original Message-
From: [EMAIL PROTECTED] [mai
Hi Johannes,
I came up with the following (assuming that if step[i] is independent of
step[i-1] then it is also independent of -step[i-1]):
Cheers Joe
> # your (unbounded) random walk
> k <- cumsum(c(0,sample(c(-1,1), 1000, rep = T)))
>
> #shift it to positive, to allow following calculation
Hi Stephen,
Check the help for predict.glm(). The argument for passing new data is
actually 'newdata', as in:
> pred = predict(glm.model, newdata=form[150001:20,-1],
> type="response")
Cheers Joe
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of
Hi,
You can exit out of the 'identify()' routine by either:
right-click > 'stop'
Or
click on 'stop > stop locator' in the top-left of the plot window.
The script should continue with line1, line2 etc.
Cheers Joe
Joe Crombie
Information and Risk Sciences
Bureau of Rural Science
Canberr
Hi Fang,
An easy way of doing this is by:
> matplot(one, pch = LETTERS[1:4], type = 'b')
Cheers Joe
Joe Crombie
Information and Risk Sciences
Bureau of Rural Science
Canberra Australia
p: +61 2 6272 5906
e: [EMAIL PROTECTED]
-Original Message-
From: [EMAIL PROTECTED] [mailto:[
Or maybe:
> while(length(ind <- identify(x,y,n = 1, plot = F)))
> points(x[ind], y[ind], pch = 19)
(highlights each point as you select it, until you click _stop_)
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Crombie, Joe
Sent: Thu
Rolf turner wrote:
>I have been trying, unsuccessfully, to use identify() to (simply)
>return a list of the indices of points clicked on and overplot (with
>say a solid dot) each clicked-on point so that I can see where I've
>been. I.e. I don't want to see the indices printed on the screen; I
8 matches
Mail list logo