MATLAB: Error using conv

convdataset

I get error when using conv function
dataset=[10 89 87 56 28 96 58 ;1 5 70 59 30 18 25 ;14 20 89 87 100 54 20]
i want to find mid point for example
A=[3 5 6 15 17 21 35 45 46 51 56 57 66 70 71]'
i get answer as
4.0000
5.5000
10.5000
16.0000
19.0000
28.0000
40.0000
45.5000
48.5000
53.5000
56.5000
61.5000
68.0000
70.5000
using code F_mid = conv(A, [0.5 0.5], 'valid')
when i use this code for my dataset
i get error
Error using ==> conv at 27
A and B must be vectors.
Error in ==> new at 3
F_mid = conv(F, [0.5 0.5], 'valid')
please help

Best Answer

The code you show that you are using is
F_mid = conv(A, [0.5 0.5], 'valid')
but your error message is for
F_mid = conv(F, [0.5 0.5], 'valid')
which does not occur anywhere in the code you show.
We do not have any information about the shape of F.