-1
$\begingroup$

I have a feature set that contains approximately 2 dozen features of technical analysis indicators. My own domain knowledge tells me that some of these features are better than others for predicitive power. But what methodical processes do I follow other than 'just a hunch', to go about refining the feature set to ones that matter the most?

At the moment, I'm just using sklearns preprocessing package and I just throw all the features in, but I know that there must be a better way.

min_max_scaler = preprocessing.MinMaxScaler()

    df[['MACD', 'MFI', 'ROC', 'RSI', 'Ultimate Oscillator', 'Williams %R', 'Awesome Oscillator', 'KAMA', 
            'Stochastic Oscillator', 'TSI', 'Volume Accumulator', 'ADI', 'CMF', 'EoM', 'FI', 'VPT','ADX', 'ADX Negative', 'ADX Positive', 
            'EMA', 'CRA']] = min_max_scaler.fit_transform(df[['MACD', 'MFI', 'ROC', 'RSI', 'Ultimate Oscillator', 'Williams %R', 'Awesome Oscillator', 'KAMA', 
            'Stochastic Oscillator', 'TSI', 'Volume Accumulator', 'ADI', 'CMF', 'EoM', 'FI', 'VPT','ADX', 'ADX Negative', 'ADX Positive', 
            'EMA', 'CRA']])

I'm quite new to machine learning and would love some feedback. I am using Pandas and Sklearn as well.

$\endgroup$

1 Answer 1

0
$\begingroup$

Please read about feature selection. Have you are a bunch of methods:

  • Univariate Selection
  • Feature Importance
  • Correlation Matrix with Heatmap

Check them out and choose the best. Sample implementation you find at the link: https://towardsdatascience.com/feature-selection-techniques-in-machine-learning-with-python-f24e7da3f36e

$\endgroup$
6
  • $\begingroup$ I had considered using the correlation method, as it seems the most logical and intuitive. Some of the other methods appear slightly more confusing however I will give them a read. $\endgroup$ Commented Mar 28, 2020 at 15:16
  • $\begingroup$ I understand that some methods such as univariate selection also only works with non-negative features. $\endgroup$ Commented Mar 28, 2020 at 15:19
  • $\begingroup$ Indeed, but you should know methods from link its only a few samples from wide range of feature selection methods. You could find other techniques in various sources. Read carefully assumptions of every method and use them. Feature selection its quite hard topic. $\endgroup$
    – fuwiak
    Commented Mar 28, 2020 at 15:24
  • $\begingroup$ Should my data me normalized/ scaled etc before, or after, feature selection? $\endgroup$ Commented Mar 28, 2020 at 15:27
  • 1
    $\begingroup$ In my case, I'm using a non-linear SVM for classification. I've decided not to normalise my data, but rather to scale it uses sklearns standard scaler, is this method good? $\endgroup$ Commented Mar 28, 2020 at 15:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.