similar to: Random sampling while keeping distribution of nearest neighbor distances constant.

Displaying 20 results from an estimated 8000 matches similar to: "Random sampling while keeping distribution of nearest neighbor distances constant."

2007 Oct 03
2
Speeding up simulation of mean nearest neighbor distances
I've written the function below to simulate the mean 1st through nth nearest neighbor distances for a random spatial pattern using the functions nndist() and runifpoint() from spatsat. It works, but runs relatively slowly - would appreciate suggestions on how to speed up this function. Thanks. --Dale library(spatstat) sim.nth.mdist <- function(nth,nsim) { D <- matrix(ncol=nth,
2012 Mar 22
3
How to get the input of a function right?
Hi, I wrote a function with three inputs fun(x,y,z). x is a matrix of three vectors combined with cbind. e.g. x1<-(1,2,3,4) x2<-(2,3,4,5) x3<-(3,4,5,6) x<-cbind(x1,x2,x3) y is a vector e.g y<-c(7,8,9) z is a real number e.g. z<-2.5 If a give the function an input like this, I get 'NA' in return. If I give the function a vector e.g c(1,2,3) instead of 'x'
2003 Nov 05
1
fast nearest-neighbor in R?
Is fast nearest-neighbor functionality available in R? I was thinking of something along the lines of what's currently in S+SPATIALSTATS. Thanks for any information anyone might have on this. - MZ
2011 Feb 18
0
Shared nearest neighbor (SNN) clustering algorithm implementation?
Hello, is there an implementation available for a shared nearest neighbor (SNN) clustering algorithm? //Jay
2002 Apr 10
0
Discriminant Adaptive Nearest Neighbor
Dear R users, Is there anyone who is aware of a R or S package that has Discriminant Adaptive Nearest Neighbor (DANN) classification by Hastie and Tibshirani? I have used the search services in R website but no luck. Thanks in advance! Jonathan -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-help mailing list -- Read
2007 Jul 08
0
Is there Discriminant Adaptive Nearest Neighbor classification?
Hello everyone, Is there anyone who is aware of any R package that has Discriminant Adaptive Nearest Neighbor (DANN) classification by Hastie and Tibshirani? Thanks in advance! Tracy [[alternative HTML version deleted]]
2004 Jul 08
1
k nearest neighbor prediction
Hi there fellow R-users, Does anyone know if there is a package for k nearest neighbours prediction as opposed to classification? I have found the package knncat but can't see a way to adjust it to predict a continuous variable. Any help would be great, Regards Wayne Jones KSS Ltd Seventh Floor St James's Buildings 79 Oxford Street Manchester M1 6SS England Company
2004 Feb 02
2
Nearest Neighbor Algorithm in R -- again.
Several of the methods I use for analyzing large data sets, such as WinGamma: determining the level of noise in data Relief-F: estimating the influence of variables depend on finding the k nearest neighbors of a point in a data frame or matrix efficiently. (For large data sets it is not feasible to compute the 'dist' matrix anyway.) Seeing the proposed solution to "[R] distance
2016 Apr 04
4
[Bug 94817] New: Nearest neighbor scaling?
https://bugs.freedesktop.org/show_bug.cgi?id=94817 Bug ID: 94817 Summary: Nearest neighbor scaling? Product: xorg Version: unspecified Hardware: Other OS: All Status: NEW Severity: enhancement Priority: medium Component: Driver/nouveau Assignee: nouveau at
2012 May 02
2
How can a function in R handle different types of input?
Hi, How can a function in R handle different types of input? I have written a function, which should calculate the slope from several 3-time-point measurements by linear regression 4 three-time-point-measurements: x<-cbind(c(1,2,3,4),c(2,3,4,5),c(3,4,5,6)) time points: time<-c(1,3,9) function for calculating the slope by linear regression: fit<-function(xx,t){slope <-
2012 Jul 24
3
Nearest Neighbors
I was wondering if there is a way in R to find k nearest neighbors of various orders, say order 2, 3, or 4. In otherwords neighbors of neighbors of neighbors. You get the idea. I know that I can use knearneigh(matrix.data, k) but this only gives me the k nearest neighbors and not of a particular order. Thanks in advance. -- View this message in context:
2001 Jan 10
2
nearest neighbors
Is there an implementation of a reasonable k-nearest neighbor finder already in one of the packages? -- +---------------------------------------------------------------------------+ | Robert Gentleman phone : (617) 632-5250 | | Associate Professor fax: (617) 632-2444 | | Department of Biostatistics office: not yet
2013 Apr 15
2
nearest stations in distance matrix
Dear R-user, Is there a way in R to locate the nearest 5 indices to a station, based on distances in a distance matrix. In other words i want to have nearest stations based on the distances in the matrix. The distance matrix, i have, has dimension 44*44. Thankyou very much in advance Elisa [[alternative HTML version deleted]]
2009 Jan 09
3
create sequences from two "from" and "to" vectors
hi all, how can I create sequences that start from a known vector, say x1 and end with another say x2- also suppose all the sequences will be the same length. I don't want to use a for loop x1<-c(1,2,3,4); x2<-(3,4,5,6); what I want is 1 2 3 4 2 3 4 5 3 4 5 6 Thanks ----- Yasir H. Kaheil Columbia University -- View this message in context:
2012 Mar 11
1
Which non-parametric regression would allow fitting this type of data? (example given).
Hi, I'm wondering which function would allow fitting this type of data: tmp=rnorm(2000) X.1 = 5+tmp Y.1 = 5+ (5*tmp+rnorm(2000)) tmp=rnorm(100) X.2 = 9+tmp Y.2 = 40+ (1.5*tmp+rnorm(100)) X.3 = 7+ 0.5*runif(500) Y.3 = 15+20*runif(500) X = c(X.1,X.2,X.3) Y = c(Y.1,Y.2,Y.3) plot(X,Y) The problem with loess is that distances for the "goodness of
2002 Apr 18
2
naming boxes in boxplot
Hi, this may be a too simple question, but I was not able to find how to do it. So when I boxplot two vectors, i.e. x<-rbind(1,2,3,4) y<-rbind(3,4,5,6) boxplot(x,y) , could somebody tell me how to name the two boxes as apple and banana? Thanks much, Haun __________________________________________________ -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
2003 Jun 08
6
Basic question on applying a function to each row of a dataframe
Hi, I have a function foo(x,y) and a dataframe, DF, comprised of two vectors, x & w, as follows : x w 1 1 1 2 2 1 3 3 1 4 4 1 etc I would like to apply the function foo to each 'pair' within DF e.g foo(1,1), foo(2,1), foo(3,1) etc I have tried >apply(DF,foo) >apply(DF[,],foo) >apply(DF[DF$x,DF$w],foo) However, none of the above worked. Can anyone help ?
2009 Dec 29
1
Effect of na.omit()
I had an NA in one row of my data frame, so I called na.omit(). But I do not understand where that row disappeared to. >fri=na.omit(fri) > fri Date.Only DAY Hour Min15 Quarter Arrival.Val Arrival4 1 09/05/2008 Friday 8 33 3 32 8 2 10/24/2008 Friday 21 86 4 28 7 3 10/31/2008 Friday 8 33 4 20
2011 Aug 18
1
CentOS 6 and IPv6 neighbor proxy
To route a subnet in ipv6 there are two possibilities: - add route commands for the subnet in each computer - or use neighbor proxy in the router server I prefer neighbor proxy. So I have to activate neighbor proxy in the router: sysctl -w net.ipv6.conf.all.proxy_ndp=1 and I have to add entries for each client in the subnet like ip -6 neigh add proxy
2010 Feb 24
1
Sparse KMeans/KDE/Nearest Neighbors?
hi, I have a dataset (the netflix dataset) which is basically ~18k columns and well variable number of rows but let's assume 25 thousand for now. The dataset is very sparse. I was wondering how to do kmeans/nearest neighbors or kernel density estimation on it. I tired using the spMatrix function in "Matrix" package. I think I'm able to create the matrix but as soon as I pass