Search All of the Math Forum:
Views expressed in these public forums are not endorsed by
NCTM or The Math Forum.



Re: I need optimized way to get classes
Posted:
Jun 2, 2012 8:04 AM


because i may use part of data ppp=p(M:end,:); where M is index in matrix
"Nasser M. Abbasi" <nma@12000.org> wrote in message <jqcq1a$lpd$1@speranza.aioe.org>... > On 6/2/2012 5:23 AM, besbesmany besbesmany wrote: > > sorry > > ppp=p(1:end,:); > > But, again, why not just write > > ppp = p > > What is the difference between p(1:end,:) and just p ? > > > > > "Nasser M. Abbasi"<nma@12000.org> wrote in message<jqco9g$ht2$1@speranza.aioe.org>... > >> On 6/2/2012 4:25 AM, besbesmany besbesmany wrote: > >> > >>> p = [0.8 0.1 0.1; 0.7 0.1 0.2; 0.2 0.3 0.5] > >> ... > >>> the following code: > >>> > >>> ppp=P(1:end,:); > >> > >> How is the above different from just writing > >> > >> ppp=P; > >> > >> ? > >> > >> (btw, Matlab is case sensitive, you wrote 'P' above, when you should > >> it as 'p' before. The case is different !) > >>



