Unique vector in data

Hello. I need to set a unique vector for 10 thousand samples. I would like to have one X vector and correspondent Y vectors. I imagine it by comparing all X vectors and choose the largest part of X vector which occur in all the others. Any ideas how to implement it in Matlab. Thanks a lot
[EDITED, relocated from answers section, Jan]
I have a mass spectrometry data. This data are arranged in two columns. The rows are about 6 thousand size. The first row is the X axis of the spectrum (mass) and the second is the Y axis of the spectrum (intensity) There are about 11 thousand samples. I need to scan all the samples in order to find such a part of X scale which will occur the most in all the samples. Then i need to interpolate this samples (Y values) which have other vector X than the best one. My question is how to find in Matlab the best part of vector through all the samples. Is there any useful function or do you have any helpful idea. Thanks a lot.

5 Comments

Jan
Jan on 5 Aug 2013
Edited: Jan on 5 Aug 2013
Which of the vectors X and Y should be unique? What are the "X vector*s*"? I think it is one vector only. How do you measure "largest part"? Does this mean the number or value of the elements? Where does Y come into play? What is the relation to the tag "interpolation"?
Currently the question is not clear. Please rephrase it and post a small example. It is recommended to edit the original question and not to hide the additional information in a comment or a pseudo-answer, because then the reader find all useful information where he/she expects it. Thanks.
Jan
Jan on 6 Aug 2013
Edited: Jan on 6 Aug 2013
I asked you explicitly to post the new information by editing the question, not by creating a pseudo-answer. I've suggested this, because it increases the quality of the question and therefore your chance to get an useful answer.
In addition you have posted a new thread also, which seems to contain exactly the same question. Please avoid such double-postings, because they confuse the readers and wastes their time.
I still do not understand the question. Please post, what you have tried so far and ask a specific question. It is very hard to solve vaguely described general problems.
Jonasz
Jonasz on 6 Aug 2013
I will show you some example:
assume you have a 10 thousand samples of two columns ( X and Y values in cartesian coordinates). The X values are not the same they differ from each other (scale, range ect). Your task is to find the best range for your samples (I mean the range which is in all the samples) so that you can compare the samples. How to find it in the easiest way in Matlab.
dpb
dpb on 6 Aug 2013
Make up a sample dataset that is, say, 20 samples long and post it and the desired solution and how you arrived at that solution logically. The description still isn't clear enough to be able to design a solution.
My first thought is
doc xcorr
but then again, that doesn't really meet the description but I can't figure out what you have for spectroscopy data that has such an issue on the channels--I've done a lot of gamma-spec over the years but never had a problem I'd describe as you've done so am at a loss...
Jan
Jan on 6 Aug 2013
Are you searching for the overlap between the X values of 10'000 different matrices? What exactly is a "sample"? There might be a large overlapping area for 9999 "samples", but the last one is completely distinct. Was is "good" or "best" then?
Currently the question is not clear. Perhaps you are simply looking for the maximum of the minimal values and minimum of the maximal values of each sample.

Answers (0)

This question is closed.

Products

Asked:

on 5 Aug 2013

Closed:

on 20 Aug 2021

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!