Displaying 20 results from an estimated 200 matches similar to: "Is there a way to round numbers up or down to the nearest "natural looking" number?"
2001 Nov 08
3
Problem with optim (method L-BFGS-B)
Hello,
I've just a little problem using the function optim.
Here is the function I want to optimize :
test_function(x){(exp(-0.06751 + 0.25473*((x[1]-350)/150) +
0.04455*((x[2]-40)/20) + 0.09399*((x[3]-400)/100) -
0.17238*((x[4]-250)/50)-
0.45984*((x[5]-550)/150)-0.39508*((x[1]-350)/150)* ((x[1]-350)/150) -
0.05116*((x[2]-40)/20)* ((x[2]-40)/20) -
0.27735*((x[3]-400)/100)*((x[3]-400)/100) -
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
2004 Feb 25
0
k nearest neighbours between two matrix
I have two dataframes A and B consisting of latitude longitude coordinates
of points. For each point in A I want to find the k-nearest neighbours in B.
Currently, I calculate the distance from each point in A to all the points
in B (using rdist.earth() in fields package), sort the points of B by
distance and select the k nearest ones.
Is there a more efficient way to do this?
Function knearneigh
2012 Apr 26
0
nearest positive semidefinit toeplitz matrix
hHllo,
I'm looking for an algroithm to transform an existing toeplitz matrix
(autocorrelation matrix) to the nearest positive semidefinite toeplitz
matrix.
I merely found an algorithm to transform an correlation matrix via the
function nearcor() based on the algorithm of Higham.
But as I examined, it destroys the toeplitz structure of my underlying
matrix.
Does any function already exist
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]]
2006 Jan 19
0
obtaining ROC curve from Nearest Shrunken Centroids (pamr)
Hello,
I have binary labels from a nearest shrunken centroids prediction
(package pamr). I need to obtain a ROC curve for this test. What is the
easiest way to obtain one?
Paolo Sonego
2010 Apr 27
1
[LLVMdev] The nearest basic block being dominated by all used values.
Hello,
Presumably I have two value v1 and v2 from two different basic block A
and B. Now I need to insert to a printf to print those two values at
the same time.
This means I need to find a basic block to insert such a calling
isntruction and at the same time, the basic block should be dominated
by v1 and v2. Is there any easy way to find such a basic block?
Cheers,
Zheng
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
2004 Jun 22
1
k nearest neighbours
Hi there fellow R-users,
Does anyone know of a function which does exactly what knearneigh{spdep}
(finds the k nearest neighbours) does in the package spdep but for more than
2D data?
Regards
Wayne
KSS Ltd
Seventh Floor St James's Buildings 79 Oxford Street Manchester M1 6SS England
Company Registration Number 2800886
Tel: +44 (0) 161 228 0040 Fax: +44 (0) 161 236 6305
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
2007 Apr 08
0
locate nearest value in lookup table
Hi everyone,
I have a pile of data derived from an analytical device, which reports
values as a continuous distribution. I need to associate classes
(based on the Munsell color system) using a standard look-up table -
the problem is that I would like to find the *closest* matching entry
in the lookup table.
I have attempted to do this by first creating as difference vector
between color space
2009 Oct 30
1
Applying a function on n nearest neighbours
I'm having a problem where I have to apply a function to a subset of a
variable, where the subset is defined by the n nearest neighbours of a
second variable.
Here's an example applied to the 'iris' dataset:
$ head(iris)
Sepal.Length Sepal.Width Petal.Length Petal.Width Species
1 5.1 3.5 1.4 0.2 setosa
2 4.9 3.0 1.4
2009 Nov 17
0
Re place NA values in matrix with the value of Nearest Neighbour
I am extracting climate data for coastal areas from 5km grid data for
specific xy coordinates that relates to individual study sites (SQ). Code so
far:
setwd("/Users/roblewis/Documents/PhD/Climate Data")
fnamestemp=read.table("Path_Directory_Maxt")
fnames=paste(fnamestemp[,1],fnamestemp[,2])
nfiles = length(fnames)
xy=as.matrix(read.table("xy_.txt"))
2012 Jun 20
1
nearest neighbours and their ID
Dear R users,
I used nndist() to gain the distance of 2 nearest
neighbours of the points in my dataset. Is there a way of getting the ID numbers
of these nearest neighbours (along with their distances).
The command I used: nn2 <- nndist(X2, k=1:2). This is the output of the nearest neighbour distances I got (the IDs of the given points are there but their IDs aren't). Any help or
2010 Mar 09
1
create picture (k -the nearest neighbours)
Hi
I want to create a nice picture about my result of k -the nearest neighbours
algorithm. Here is my easy code:
#################################
library(klaR)
library(ipred)
library(mlbench)
data(PimaIndiansDiabetes2)
dane=na.omit(PimaIndiansDiabetes2)[,c(2,5,9)]
dane[,2]=log(dane[,2])
dane[,1:2]=scale(dane[,1:2])
zbior.uczacy=sample(1:nrow(dane),nrow(dane)/2,F)
2009 Aug 17
4
Rounding to the nearest 5
Dear all,
A hopefully simple question: how do I round a series of values (held in an object) to the nearest 5? I've checked out trunc, round, floor and ceiling, but these appear to be more tailored towards rounding decimal places.
Thanks,
Steve
_________________________________________________________________
icons.
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
2004 Apr 06
1
k nearest neighbours
I want to
1) Select for each of the n points in a matrix A, those of the m points
in B that lay within a given radius.
2) Of those points within the radius, select the k nearest ones.
What I now do is
1) Create an n*m matrix C were I put the distances from all the points
in B to the points in A and make NA those cells were the distance is
larger than the radius. (The points are geographical
2009 Nov 30
4
Is there a way to convert rgb/hex value to a (nearest) color name?
Hi all, I'm trying to convert a series of rgb codes into a color name.
What is my easiest option? So far I'm stuck with just converting to
hex using rgb() and I know R knows a number of colours() but a mapping
of the two has failed me.
Any help in this regard will be highly appreciated.
Regards,
George