Questions tagged [multi-dimensional-scaling]
84 questions
3
votes
1 answer
Java MDSJ produces NaN
Anyone have any experience with MDSJ? The following input produces only NaN results and I can't figure out why. The documentation is pretty sparse.
import mdsj.Data;
import mdsj.MDSJ;
public class MDSJDemo {
public static void main(String[]…

Nick Heiner
- 119,074
- 188
- 476
- 699
2
votes
2 answers
R extract distance between centroids to data frame using Vegan
I have a biological data set where I want to calculate the distance between centroids and each centroid represents a given year (so distance is calculated sequentially). I'm exploring usedist::dist_between_centroids() to calculate the distance in…

Joshua Smith
- 125
- 6
2
votes
1 answer
Is it possible to find similar orders by multi-dimensional scaling in scikit learn?
I have several files containing 3D positions of 10 points (as plotting in corresponding pictures). I would like to use multi-dimensional scaling to find similar orderings and print out different orderings. For example, here ordering from text file…

Binh Thien
- 363
- 2
- 13
2
votes
1 answer
Row-wise correlation between two matrices
I have the following matrices :
And:
I want to calculate their row-wise pearson correlations and I've tried these pieces of code:
RowCor<- sapply(1:21, function(i) cor(EurodistCL.scl[i,], EurodistM.scl[i,], method = "pearson"))
And:
cA <-…

q0mlm
- 313
- 1
- 3
- 10
2
votes
0 answers
How to measure distance when applying MDS
Hi I have a very specific, weird question about applying MDS with Python.
When creating a distance matrix of the original high dimensional dataset (let’s call it distanceHD) you can either measure those distances between all data points with…

Johnny521
- 61
- 2
- 6
2
votes
1 answer
How to obtain the eigenvalues after performing Multidimensional scaling?
I am interested in taking a look at the Eigenvalues after performing Multidimensional scaling. What function can do that ? I looked at the documentation, but it does not mention Eigenvalues at all.
Here is a code sample:
mds =…

Uther Pendragon
- 302
- 2
- 14
2
votes
0 answers
compare multidimensional scaling matrix
I have two MDS plot for the same 356 items, what is the best thing that I can do to compare these two plots?
I tried to use Procrustes in R but I did not like the result that I get is there another functions I can use in R to compare them?
dat1 <-…

user4544869
- 53
- 1
- 5
2
votes
1 answer
Use similarity matrix instead of dissimilarity matrix for MDS in scikit-learn
I want to visualize similarity of text documents for which I am using scikit-learn's TfidfVectorizer as tfidf = TfidfVectorizer(decode_error='ignore', max_df=3).fit_transform(data)
and then performing cosine similarity calculation as…

yogk
- 271
- 5
- 15
2
votes
1 answer
Multidimensional scaling (MDS) on iris dataset
I should do multidimensional scaling with "mdscale" function in matlab on the famous Fisher Iris dataset.
I don't get why sometimes it works and sometimes not. This is what I do:
clear all;
load('fisheriris'); %it return a dataset in the variable…

Ewybe
- 395
- 2
- 4
- 15
1
vote
0 answers
Error when trying to do Multi-Dimensional Scaling in python
I am trying to get 2D coordinates between 0 and 1 from a distance matrix, following the methods that are specified in the following posts (Multi-Dimensional…

sarasataco
- 11
- 2
1
vote
3 answers
Dynamic array of array of int in C
How can an array of array of int be declared outside the main, then build inside the main once we know the length of the array of array we want to build, if one dimension is already known.
For example, if the array should be array[numberofargs][2],…

CoffeeRun
- 71
- 6
1
vote
1 answer
Perform Multi-Dimension Scaling (MDS) for clustered categorical data in python
I am currently working on clustering categorical attributes that come from a bank marketing dataset from Kaggle. I have created the three clusters with kmodes:
Output: cluster_df
Now I want to visualize each row of a cluster as a projection or point…

koocer
- 33
- 5
1
vote
0 answers
Python: plotting precomputed distance matrix with sklearn manifold
In Python 3.6.3, I have a precomputed distance matrix D:
In[1]: D
Out[1]:
array([[0.00, 305923.00, 269966.00, 349816.00, 304120.00, 326591.00,
341136.00, 254420.00, 228892.00, 344290.00],
[305923.00, 0.00, 13901.00, 288851.00,…

FaCoffee
- 7,609
- 28
- 99
- 174
1
vote
0 answers
3 y's with different scales plotted with matplotlib
I want to plot a function, and show 3 different y axis, each one with different scales, logarithmic and linear scales. I followed this and this other examples trying to modify it to take into account the difference I mentioned before.
EDIT: I have…

Jorge
- 11
- 3
1
vote
0 answers
Matrix V for Guttman transform in R
I'm trying to write a code to get matrix V. V is given as see image. Wij is matrix(1,n,n)
This it what I have so far but it gives me a matrix of only 1's and 11's. It think this is not right. Can someone tell me what I'm doing wrong?
V <-…

Xi Ling
- 11
- 2