Trending questions in Data Science

0 votes
0 answers

Calculate correlation with cor(), only for numerical columns

I have a dataframe and would like ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
244 views
0 votes
0 answers

understanding durbin-watson test in R

I believe I have a misconception about ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
234 views
0 votes
1 answer

How to make loop for one-at-a time logistic regression in R?

You're probably looking for something similar to ...READ MORE

Jun 20, 2022 in Data Science by Sohail
• 3,040 points
779 views
0 votes
1 answer

How to implement Knn-algorithm without using k-nn function in r?

I created an example that demonstrates the ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
269 views
0 votes
1 answer

Using dcast to widen a data frame

> dcast(z, id ~ item, value.var="freq") ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
265 views
0 votes
0 answers

To speed up the tapply function in R, or another function to convert data frame into a matrix

I must turn a sizable dataset into ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
204 views
0 votes
1 answer

Add two lines on graph using abline in R

I am using "y 0+x" to fit ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
392 views
0 votes
1 answer

unique() for more than one variable

df <- data.frame(yad = c("BARBIE", "BARBIE", "BAKUGAN", ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
191 views
0 votes
1 answer

rnorm function in R - Usage

y = rnorm(12, rep(c(1,2,1), each=4, 0.2)) I can ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
304 views
0 votes
1 answer

Changing column names of a data frame

import pandas as pd #define DataFrame df = pd.DataFrame({'team':['A', ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
269 views
0 votes
1 answer

Why is it not advisable to use attach() in R, and what should I use instead?

There is one more option that applies ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
289 views
0 votes
1 answer

How to join (merge) data frames (inner, outer, left, right)

The merge function and its optional parameters ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
206 views
0 votes
1 answer

How To Create Vector of Vector In R

Create a list: List() on x returns x[[1]] ...READ MORE

Jun 24, 2022 in Data Science by Sohail
• 3,040 points
276 views
0 votes
1 answer

Difference between the == and %in% operators in R

percent in percent "returns a vector of ...READ MORE

Jun 20, 2022 in Data Science by Sohail
• 3,040 points
439 views
0 votes
1 answer

The difference between Map() and map () from Purrr package in R

The tilde just indicates to the map ...READ MORE

Jun 14, 2022 in Data Science by Sohail
• 3,040 points
280 views
0 votes
1 answer

plotting in different shapes using pch= argument

plot(Sepal.Length ~ Petal.Length, ...READ MORE

Jun 23, 2022 in Data Science by Sohail
• 3,040 points
288 views
0 votes
1 answer

Test if a vector contains a given element

1. Making use of the std::count function Counting ...READ MORE

Jun 20, 2022 in Data Science by Sohail
• 3,040 points
323 views
0 votes
1 answer

Difference between the == and %in% operators in R

According to help('percent in percent'), percent in ...READ MORE

Jun 23, 2022 in Data Science by Sohail
• 3,040 points
231 views
0 votes
0 answers

how to make 2 separate substrings from strsplit in R

When it comes to accessing the elements ...READ MORE

Jun 13, 2022 in Data Science by Avinash
• 1,260 points
162 views
0 votes
1 answer

Reasons for using the set.seed function

The requirement is a desire for repeatable ...READ MORE

Jun 20, 2022 in Data Science by Sohail
• 3,040 points
222 views
0 votes
1 answer

R package dplyr reinstall every instance

In R, there are two steps of ...READ MORE

Jun 1, 2022 in Data Science by Sohail
• 3,040 points
449 views
0 votes
1 answer

do-while loop in R

Unlike for and while loops, which test the loop condition at ...READ MORE

Jun 1, 2022 in Data Science by Sohail
• 3,040 points
437 views
0 votes
1 answer

R cbind with get paste

This is how we use column names x ...READ MORE

Jun 1, 2022 in Data Science by Sohail
• 3,040 points
395 views
0 votes
1 answer

Creating new Functions with Linear Regression in R :

When we want to create a model ...READ MORE

Jun 1, 2022 in Data Science by Sohail
• 3,040 points
371 views
0 votes
0 answers

Introduction to Statistical Learning with Applications in R Figure Codes

I recently bought the following book: An Introduction ...READ MORE

Jun 1, 2022 in Data Science by avinash
• 1,840 points
371 views
0 votes
0 answers

Determine the data types of a data frame's columns

I'm using R and have loaded data ...READ MORE

Jun 1, 2022 in Data Science by avinash
• 1,840 points
186 views
0 votes
1 answer

Converting xlsx to xls using Microsoft Office Compitablity Pack's excelcnv

Simply rearranging the positions of the parameters ...READ MORE

Mar 25, 2022 in Data Science by gaurav
• 23,260 points
788 views