Skip to content
Home » how to » Page 19

how to

Pandas: Solve ‘You are trying to merge on object and int64 columns’

Pandas is the go-to package for anything data science in Python. However, if you’re used to R and the convenience of dplyr or data.table, pandas can be confusing, now and then. For example, the following error is a real newb issue. ValueError: You are trying to merge on object and… 

Storing a K-means model in R

  • by
  • 2 min read

K-means clustering is quick and dirty and generally provides some interesting results. However, the default kmeans function in R lacks features, such as actually storing the model to use the centroids for prediction purposes on unseen data. That’s where flexclust comes in. Flexclust is a package that is designed around… 

Solve Microsoft Office turning ‘revenue’ into ‘revenu’

Every time the word ‘revenue’ turns into ‘revenu’ because Microsoft Office thinks it is a good idea, I start bleeding from my eyes. Hundreds of bloody tissues later, I finally decided to fix it. And it’s surprisingly easy. Apparenty, there is a rule in the Dutch (Nederlands) AutoCorrect that is…