Info

This question is closed. Reopen it to edit or answer.

How to create an if statement that will match dates and perform function

1 view (last 30 days)
Hi
I have multiple data sets with different dates and associated conductivity readings to the dates. Some of the dates match and overlap each other.
I would like to create a code that checks if the dates match or are within 30 minutes it will run correlation statistics on the conductivity data.
I have been trying to use xcorr and or acor, these don't work because the matrices don't match.
Any help is greatly appreciated!!!
Here is an example of my data:
1 Data Set
735903.398310185 417.660000000000
735903.408726852 417.630000000000
735903.419143519 417.650000000000
735903.429560185 417.630000000000
735903.439976852 417.800000000000
735903.450393519 417.580000000000
735903.460810185 417.640000000000
735903.471226852 417.620000000000
735903.481643519 417.610000000000
735903.492060185 417.690000000000
735903.502476852 417.640000000000
735903.512893519 417.600000000000
735903.523310185 417.530000000000
735903.533726852 417.610000000000
735903.544143519 417.610000000000
735903.554560185 417.610000000000
735903.564976852 417.610000000000
735903.575393519 417.620000000000
735903.585810185 417.620000000000
735903.596226852 417.770000000000
735903.606643519 417.650000000000
735903.617060185 417.800000000000
735903.627476852 417.620000000000
735903.637893519 417.620000000000
735903.648310185 417.610000000000
735903.658726852 417.690000000000
735903.669143519 417.520000000000
735903.679560185 417.610000000000
735903.689976852 417.610000000000
735903.700393519 417.600000000000
735903.710810185 417.660000000000
735903.721226852 417.660000000000
735903.731643519 417.600000000000
735903.742060185 417.590000000000
735903.752476852 417.590000000000
735903.762893519 417.590000000000
735903.773310185 417.670000000000
735903.783726852 417.590000000000
735903.794143519 417.590000000000
735903.804560185 417.590000000000
735903.814976852 417.590000000000
735903.825393519 417.600000000000
735903.835810185 417.590000000000
735903.846226852 417.590000000000
735903.856643519 417.500000000000
735903.867060185 417.500000000000
735903.877476852 417.590000000000
735903.887893519 417.580000000000
735903.898310185 417.580000000000
735903.908726852 417.590000000000
735903.919143519 417.500000000000
735903.929560185 417.590000000000
735903.939976852 417.500000000000
735903.950393519 417.580000000000
735903.960810185 417.490000000000
735903.971226852 417.570000000000
735903.981643519 417.500000000000
735903.992060185 417.570000000000
735904.002476852 417.490000000000
735904.012893519 417.570000000000
735904.023310185 417.400000000000
735904.033726852 417.570000000000
735904.044143519 417.490000000000
735904.054560185 417.490000000000
735904.064976852 417.490000000000
735904.075393519 417.490000000000
735904.085810185 417.490000000000
735904.096226852 417.400000000000
735904.106643519 417.490000000000
735904.117060185 417.490000000000
735904.127476852 417.560000000000
735904.137893519 417.470000000000
735904.148310185 417.390000000000
735904.158726852 417.460000000000
735904.169143519 417.460000000000
735904.179560185 417.370000000000
735904.189976852 417.440000000000
735904.200393519 417.440000000000
735904.210810185 417.430000000000
735904.221226852 417.430000000000
735904.231643519 417.430000000000
735904.242060185 417.420000000000
735904.252476852 417.420000000000
735904.262893519 417.420000000000
735904.273310185 417.330000000000
735904.283726852 417.410000000000
735904.294143519 417.410000000000
735904.304560185 417.380000000000
735904.314976852 417.370000000000
735904.325393519 417.350000000000
735904.335810185 417.230000000000
735904.346226852 417.280000000000
735904.356643519 417.260000000000
735904.367060185 417.260000000000
735904.377476852 417.300000000000
735904.387893519 417.230000000000
735904.398310185 417.130000000000
735904.408726852 417.180000000000
735904.419143519 417.120000000000
735904.429560185 417.080000000000
735904.439976852 417.020000000000
735904.450393519 416.900000000000
735904.460810185 416.890000000000
735904.471226852 416.970000000000
735904.481643519 416.980000000000
735904.492060185 416.900000000000
735904.502476852 417.060000000000
735904.512893519 416.980000000000
735904.523310185 416.980000000000
735904.533726852 416.980000000000
735904.544143519 416.980000000000
735904.554560185 416.980000000000
735904.564976852 416.900000000000
2nd Dataset
735899.651446759 490.370000000000
735899.661863426 490.290000000000
735899.672280093 490.290000000000
735899.682696759 490.370000000000
735899.693113426 490.370000000000
735899.703530093 490.290000000000
735899.713946759 490.290000000000
735899.724363426 490.130000000000
735899.734780093 490.210000000000
735899.745196759 490.210000000000
735899.755613426 490.210000000000
735899.766030093 490.290000000000
735899.776446759 490.210000000000
735899.786863426 490.210000000000
735899.797280093 490.210000000000
735899.807696759 490.290000000000
735899.818113426 490.210000000000
735899.828530093 490.290000000000
735899.838946759 490.370000000000
735899.849363426 490.210000000000
735899.859780093 490.290000000000
735899.870196759 490.290000000000
735899.880613426 490.370000000000
735899.891030093 490.290000000000
735899.901446759 490.290000000000
735899.911863426 490.130000000000
735899.922280093 490.130000000000
735899.932696759 490.130000000000
735899.943113426 490.130000000000
735899.953530093 490.210000000000
735899.963946759 490.130000000000
735899.974363426 490.130000000000
735899.984780093 490.130000000000
735899.995196759 490.210000000000
735900.005613426 490.130000000000
735900.016030093 490.050000000000
735900.026446759 490.130000000000
735900.036863426 490.130000000000
735900.047280093 490.130000000000
735900.057696759 490.130000000000
735900.068113426 490.050000000000
735900.078530093 490.210000000000
735900.088946759 490.130000000000
735900.099363426 490.130000000000
735900.109780093 490.050000000000
735900.120196759 490.130000000000
735900.130613426 490.130000000000
735900.141030093 495.270000000000
735900.151446759 494.420000000000
735900.161863426 494.260000000000
735900.172280093 494.100000000000
735900.182696759 494.030000000000
735900.193113426 493.950000000000
735900.203530093 493.870000000000
735900.213946759 493.870000000000
735900.224363426 493.790000000000
735900.234780093 493.950000000000
735900.245196759 493.870000000000
735900.255613426 493.870000000000
735900.266030093 493.870000000000
735900.276446759 493.870000000000
735900.286863426 493.950000000000
735900.297280093 493.950000000000
735900.307696759 494.100000000000
735900.318113426 494.420000000000
735900.328530093 494.340000000000
735900.338946759 494.260000000000
735900.349363426 494.260000000000
735900.359780093 494.420000000000
735900.370196759 494.260000000000
735900.380613426 494.260000000000
735900.391030093 494.180000000000
735900.401446759 494.340000000000
735900.411863426 494.340000000000
735900.422280093 494.260000000000
735900.432696759 494.260000000000
735900.443113426 494.180000000000
735900.453530093 494.260000000000
735900.463946759 494.180000000000
735900.474363426 494.100000000000
735900.484780093 494.180000000000
735900.495196759 494.180000000000
735900.505613426 494.100000000000
735900.516030093 494.180000000000
735900.526446759 494.030000000000
735900.536863426 494.030000000000
735900.547280093 494.030000000000
735900.557696759 494.030000000000
735900.568113426 494.030000000000
735900.578530093 494.030000000000
735900.588946759 493.950000000000
735900.599363426 494.030000000000
735900.609780093 493.950000000000
735900.620196759 494.030000000000
735900.630613426 493.790000000000
735900.641030093 493.870000000000
735900.651446759 493.250000000000
735900.661863426 493.090000000000
735900.672280093 493.090000000000
735900.682696759 493.090000000000
735900.693113426 493.010000000000
735900.703530093 493.090000000000
735900.713946759 492.940000000000
735900.724363426 493.090000000000
735900.734780093 493.010000000000
735900.745196759 493.010000000000
735900.755613426 493.010000000000
735900.766030093 492.940000000000
735900.776446759 492.940000000000
735900.786863426 492.940000000000
735900.797280093 493.170000000000
735900.807696759 493.090000000000
735900.818113426 493.090000000000
735900.828530093 493.090000000000
735900.838946759 492.940000000000
735900.849363426 492.940000000000
735900.859780093 493.010000000000
735900.870196759 493.010000000000
735900.880613426 492.940000000000
735900.891030093 493.090000000000
735900.901446759 492.940000000000
735900.911863426 493.010000000000
735900.922280093 492.940000000000
735900.932696759 492.940000000000
735900.943113426 492.940000000000
735900.953530093 492.940000000000
735900.963946759 492.860000000000
735900.974363426 492.860000000000
735900.984780093 493.170000000000
735900.995196759 493.250000000000
735901.005613426 493.170000000000
735901.016030093 493.170000000000
735901.026446759 493.090000000000
735901.036863426 493.090000000000
735901.047280093 493.090000000000
735901.057696759 493.090000000000
735901.068113426 493.010000000000
735901.078530093 493.090000000000
735901.088946759 493.010000000000
735901.099363426 492.860000000000
735901.109780093 492.940000000000
735901.120196759 492.620000000000
735901.130613426 492.700000000000
735901.141030093 492.700000000000
735901.151446759 493.330000000000
  1 Comment
dpb
dpb on 4 Dec 2014
Use the paperclip and attach a file instead of pasting so much, please...
W/O a second set for comparison tough to do a specific but look at
doc pdist2 % and friends
intersect will find the exact matches, of course...

Answers (0)

Products

Community Treasure Hunt

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

Start Hunting!