πŸ“Š Pandas
Q. Which pandas method is used to randomly sample rows from a DataFrame?
  • (A) sample()
  • (B) rand()
  • (C) shuffle()
  • (D) take()
πŸ’¬ Discuss
βœ… Correct Answer: (A) sample()

Explanation: The sample() method returns a random sample of rows or columns from a DataFrame.

Explanation by: Sikhar Chaudhary
The sample() method returns a random sample of rows or columns from a DataFrame.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
52
Total Visits
πŸ“½οΈ
8 mo ago
Published
πŸŽ–οΈ
Sikhar Chaudhary
Publisher
πŸ“ˆ
86%
Success Rate