How to find the index in 1D array that has closest value to some number ?
val =-1.03val1 = 1.04x = -10:0.009:10ind1 = find (A==val) % will work if the val is exact match
arrayfindindexindexingMATLAB
val =-1.03val1 = 1.04x = -10:0.009:10ind1 = find (A==val) % will work if the val is exact match
Best Answer