|
|
Re: data extract
Posted:
May 26, 2009 8:14 AM
|
|
"Bizuayehu Mohammed" <bisaye@gmail.com> wrote in message <gvgimb$l4r$1@fred.mathworks.com>... > I want to extract a couple of datas from a data which is captured through serial port device. The datas are in text file (notepad) and I can call on matlab the problem is I want to take selected data`s from the note pad to plot a real time graph. > The data formats are like this > ...‚B01DA,20,2,L,49.98,11.96,3.35,2.35,2.55,890,264,93,1205.006,860,P\?...‚.20D20?G.. > .‚B02DA,20,2,L,50.06,11.96,3.30,2.45,2.65,865,255,93,1205.008,928,P.?.. > .‚.10D30?D...‚?01DA,30,2,S,P,L,P,S,P,M,P,P,R,N,N,D,E,S,80010.,99.999,0.08333?Ÿ.. > .‚.20D30?I...‚?02DA,30,2,L,P,L,P,N,P,M,P,P,R,N,N,D,E,S,1457.6,99.994,0.08333.W.. > .‚.10D31?E...‚101DA,31,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,M,0,1?:...‚.20D31?J.. > .‚102DA,31,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,P,M,0,1vh...‚.10D32?F...‚ > As you can see the datas are separated by coma but they have a catagory > 1. The first catagory is they are separated by 3 dots and a comma from each data set > 2. The datas I want to extract are > B01DA,20,2,L,49.98,11.96,3.35,2.35,2.55,890,264,93,1205.006,860,P\? > and > B02DA,20,2,L,50.06,11.96,3.30,2.45,2.65,865,255,93,1205.008,928,P.? > types > these selected datas are keep changing in certain limits except for the first 3 values, and the length of these datas is 15 so I would really appreciate any hint regarding this. > Many Thanks
Me Again I now programmed and have made some manipulation now my question is how to extract some datas from a collective datas The new program gives the following results. 80 80 20 2 50 12 3 2 3 890 264 93 1205 860 20 2 50 12 3 2 3 865 255 93 1205 928 30 2 32767 100 30 2 1458 100 31 0 31 0 32 0 1 15 85 31 27 250 27 56 0 3 2 32 54 2 15 19 29 38 250 27 47 58 75 52 17 actually in column vector or we can change it to row vector as well my questions are 1. how to select specific values which are like this 20 2 50 12 3 2 3 890 264 93 1205 860 2. I want to see the values after decimal point I mean for example in the above data 50 is 49.96 and 1205 is 1205.006 and almost all of them have a value after a decimal point I would like to know how to do that as well. Many Thanks
|
|