Username Remember Me?
Password   forgot password?
   
   
Use custom feature selection algorithm in a pipeline
Posted: 05 March 2010 04:08 PM   [ Ignore ]  
Newbie
Rank
Total Posts:  20
Joined  2010-02-18

Hi,

I created a custom feature selection algorithm with sdalg. Is it possible to use it in a pipeline so that I can do the following thing:

sdcrossval((myalgo*sdlinear)*sddecide,data)

I tried to use sdp_fsel but I got the following error when trying it:

>> p=sdp_fsel(14[1 2 4 6])
??? 
Input argument "lab" is undefined.

Error in ==> C:\Program Files\MATLAB\R2009b\toolbox\prsd_toolbox\sdp_fsel.p>sdp_fsel at 24

Thanks

Mathieu

[ Edited: 05 March 2010 05:32 PM by Mathieu]
Profile
 
 
Posted: 08 March 2010 03:06 PM   [ Ignore ]   [ # 1 ]  
Administrator
Avatar
RankRankRankRank
Total Posts:  240
Joined  2008-04-26

Hi Mathieu,

it is not possible to combine untrained algorithms and pipelines at the moment.

sdp_fsel needs also feature labels. In 2.0 you can simply provide the data set and indices, instead of input dimensionality, indices and labels:

>> a
'medical D/ND' 6400 by 11 sddata3 classes'disease'(1495'no-disease'(4267'noise'(638
>> 
a.featlab'
   1 StdDev       
   2 Skew         
   3 Kurtosis     
   4 Energy Band 1
   5 Energy Band 2
   6 Moment 12    
   7 Moment 20    
   8 Moment 02    
   9 Moment 13    
  10 Fractal 4    
  11 Morph C      

>> pf=sdp_fsel(a,[2 3 10])
Feature subset pipeline 11x3   (sdp_fsel)
>> pf.lab
sdlab with 3 entries: '
Skew','Kurtosis','Fractal 4'

>> b=a*pf
'
medical D/ND' 6400 by 3 sddata, 3 classes: 'disease'(1495) 'no-disease'(4267) 'noise'(638) 
>> b.featlab'
   
1 Skew         
   2 Kurtosis     
   3 Fractal 4

Pavel

Profile
 
 
Posted: 08 March 2010 04:58 PM   [ Ignore ]   [ # 2 ]  
Newbie
Rank
Total Posts:  20
Joined  2010-02-18

Ok thanks, the help for sdp_fsel does’t mention anything about feature labels.

Mathieu

Profile
 
 
Posted: 08 March 2010 08:51 PM   [ Ignore ]   [ # 3 ]  
Administrator
Avatar
RankRankRankRank
Total Posts:  240
Joined  2008-04-26

I double-checked just now - the sdp_fsel help in 2.0.8 (18-feb-2010) does list the alternative syntax involving a data set.

Pavel

Profile