Answers.Body: <p>Have a look at <code>sklearn</code>'s <a href="https://scikit-learn.org/stable/modules/generated/sklearn.neural_network.MLPRegressor.html" rel="nofollow noreferrer">sklearn.neural_network.MLPRegressor</a> class, which uses a multi-layer neural network to do regression. You first need to define the object <code>MLPRegressor</code>, for example, by specifying the value of the parameter <code>hidden_layer_sizes</code>, which determines the number of layers and the number of neurons per layer, then you should call the method <a href="https://scikit-learn.org/stable/modules/generated/sklearn.neural_network.MLPRegressor.html#sklearn.neural_network.MLPRegressor.fit" rel="nofollow noreferrer"><code>fit</code></a> on this created object and pass to it your data matrix <span class="math-container">$X \in \mathbb{R}^{n \times m}$</span>, where <span class="math-container">$n$</span> is the number of samples and <span class="math-container">$m$</span> is the number of features.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-07-16T21:17:13.320Z
Answers.LastActivityDate: 2019-07-16T21:17:13.320Z
Answers.UserDisplayName: nbro
Body: <p>I want to use a neural network to perform a multivariable regression, where my dataset contains multiple features, but I can't for the life of me figure it out. Every kind of tutorial on the internet seems to be either for a single feature without information on how to upgrade it to multiple, or results in a yes or a no when I need numeric predictions (that is, it uses neural networks for classification). </p>
  
  <p>Can someone please recommend some kind of resource I can use to learn this?</p>
  
Tags: <neural-networks><python><regression>
Title: How can I perform multivariable regression with neural networks?
UserDisplayName: cjm333
ThreadText: # How can I perform multivariable regression with neural networks?
  
  (Asked by: username_0 on 2019-07-16)
  
  I want to use a neural network to perform a multivariable regression, where my dataset contains multiple features, but I can't for the life of me figure it out. Every kind of tutorial on the internet seems to be either for a single feature without information on how to upgrade it to multiple, or results in a yes or a no when I need numeric predictions (that is, it uses neural networks for classification).
  
  Can someone please recommend some kind of resource I can use to learn this?
  
  **Tags:** neural-networks, python, regression
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2019-07-16. Score: 1
  
  Have a look at `sklearn`'s [sklearn.neural\_network.MLPRegressor](https://scikit-learn.org/stable/modules/generated/sklearn.neural_network.MLPRegressor.html) class, which uses a multi-layer neural network to do regression. You first need to define the object `MLPRegressor`, for example, by specifying the value of the parameter `hidden_layer_sizes`, which determines the number of layers and the number of neurons per layer, then you should call the method [`fit`](https://scikit-learn.org/stable/modules/generated/sklearn.neural_network.MLPRegressor.html#sklearn.neural_network.MLPRegressor.fit) on this created object and pass to it your data matrix $X \in \mathbb{R}^{n \times m}$, where $n$ is the number of samples and $m$ is the number of features.
  
  
  ---
  
  