6

Test accuracy better reflects generalization error, so you want the one with higher test accuracy. In your first setup, the higher train accuracy indicates overfitting, as it's significantly higher than train accuracy. This is also kind of why it generalizes less well than the second one.


3

No, deterministic probability is when you know for certain. If a person does not have a diagnosis, then he doesn't have the disease/condition. Doctors are not supposed to give a probability but we as human beings always like to know the likelihood. For example, person A who is 27 years old who has the coronavirus is highly unlikely to die of the virus but ...


3

No. t-Distributed Stochastic Neighbor Embedding (t-SNE) and Principal Component Analysis (PCA) are dimension reduction techniques, aka fewer columns of a tidy dataframe. Clustering will reduce the number of observations, aka fewer rows of a tidy dataframe. In particular, you might be looking for hierarchical clustering.


3

Understanding the difference with an example will be very easy. Classification:- When you are asked to predict whether a patient will survive or no from a disease X given all the necessary data of the patients who survived or died due to the same disease X in the past and also given data for predicting the same on the current dataset. Regression:- When you ...


3

Alternatively to the accepted answer, another way to estimate the uncertainty of a specific prediction is to combine the probabilities returned by the model for each class using a certain function. This is a common practice in "Active learning", where given a trained model you select a subset of unlabelled instances to label (to augment the initial training ...


2

Beeing X in the future and beeing X in specific time in the future is just a subset of the first one. So what one really needs to do is just determine the probabilities (or parameters that give us these probabilities) P(X|t>30) Where you can model t, also as your feature. So just fit a model on this data, where you have mutliclassification of: dead ...


2

Single or multi label doesn't make the difference. Cross validation is only split methodology. It just divides records in your data set to separate train and test splits. Python wrapper implements scikit API, so it'll work with any of the selection methods. Metrics will work too. Just remember to one-hot encode your labels. Is using cross validation for ...


2

The cross entropy is equivalent (up to a constant) to the Kullback Leibler Divergence which has an interpretation based on information theory: (very crudely) it is the amount of information "lost" by representing the true labels via the distribution of their predicted values (measured in "nats" (e) or "bits" (2) depending on the base of the logarithm). I ...


2

To summarize from the comment thread: there are two "weird" things going on here. 1. The zig-zag. As I addressed in the comments, and @BrianSpiering in an answer, this is probably a parity effect, arising from tied votes among the nearest neighbors when $k$ is even. 2. Training accuracy not decreasing (toward test accuracy) with increasing $k$. This was ...


2

You have to set the option objective = binary:logistic to get probabilities between 0 and 1, otherwise you only get relative scores.


2

Calibration, agreement between observed and predicted risk, is more important in prognostic settings, because we would like to predict future risk of the target population, and the intercept (disease prevalence) is very important Discrimination, separating people with disease from without disease, is more important in diagnostic settings, because we want to ...


2

Discrimination is the separation of the classes while calibration gives us scores based on risk of the population. For example, there are 100 people that we’d like to predict a disease for and we know that only 3 out of 100 people have this disease. We get their probabilities from our model. Due to good predictability power, our model predicts probabilities ...


2

If you want to reduce the number of classes you are predicting over, then you could manually map them to a simpler set (i.e. map poodle, greyhound to dog ) OR if you don't have the domain knowledge you can cluster your data and predict the cluster instead of their original labels. You could use PCA or t-SNE to reduce the number of dimensions before ...


1

Do you think I implemented the code in the right way? Code is correct, but he is minimal possible. The features (X) have low correlation with the labels (Y). It's could be the biggest problem, features have to have correlation with labels. Do you have any suggestion to enhance the accuracy? Make transformation of labels(X). Preparing of labels its ...


1

So, the direct answer here is clearly NO. The answer comes from the definitions of classification and regression. In a classification task what a model predicts is the probability of an instance to belong to a class (e.g. 'image with clouds' vs 'image without clouds' ), in regression you are trying to predict continuous values (e.g. the level of '...


1

In short, AdaBoost works in that way that it trains in subsequent iterations and then measures the error of all available weak classifiers. In each subsequent iteration, the "validity" of incorrectly qualified observations is increased, so that classifiers pay more attention to them. So confusion matrix could be shown after each iteration(after 13). In case ...


1

Do I use the mean vector from my training set to center my testing set when dimension reducing for classification?: Yes. Test set must not be combined with training set in any step of calculating the reduced dimension space. Characteristics of final space is determined by training set and test set just follows that i.e. the mean-adjusting step uses ...


1

The 1176 is the number of neurons in the layer before the last layer, which is the number of pixels in the convolutional layer but flattened (height*width*n_filters, i.e. 7*7*24=1176). The 3 comes from the number of neurons in the final layer, since you have 3 classes your final layer has 3 neurons, 1 for each class (which will output zero or one). This then ...


1

You’ve asked two questions: 1) Do you make decisions about model superiority based on training or testing performance? 2) Which model should you prefer? I’ll answer both. 1) First, come over to Cross Validated (the Stack Exchange site for statistics and similar topics, with some overlap to this site) and check out what Frank Harrell has to say about ...


1

As the model is not trained to recognize an image from this new specific class, the only thing it will do, is to give a probability-or similarity measure for each of the classes for which the model has been trained on. Hence in a Classification problem, the class with the highest probability for this testing image will be the classification output.


1

There's several ways that you can choose your k value for kNN - You can use the common formula k = sqrt(n) where n is the number of data points in your training set or you can try choosing k where there is a good balance between computation expense vs noise. Consider your what fits your problem: Do you care about runtime? The higher the k, the more ...


1

If $(\beta, \beta_0)$ satisfies the inequality $(4.47)$, then for any positive $k$, $k>0$, $(k\beta, k\beta_0)$ would satisfies the inequality as well. Also, $(\hat{\beta}, \hat{\beta}_0)=\left( \frac{\beta}{M\|\beta\|}, \frac{\beta_0}{M\|\beta\|} \right)$ satiesfies the inequlity as well since $$y_i(x_i^T\hat{\beta}+\hat{\beta}_0)=\frac{y_i}{M\|\beta\|...


1

In both cases you need to know that the already trained model is not written on the stone. Specially the second question "needs" change of model. To be more detailed, you are talking about Online Learning in general. Many ML algorithms have online versions. Here, for example, you see the online version of K-means for second question. But in general, online ...


Only top voted, non community-wiki answers of a minimum length are eligible