Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7187775
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T18:55:16+00:00 2026-05-28T18:55:16+00:00

I am comparing different clustering methods and I would like to see if two

  • 0

I am comparing different clustering methods and I would like to see if two different methods (or sets of parameters) are defining similar clusters or not. My clusters are defined as categorical factors (categorical variables) in a data frame.

If I use plot() with x being a categorical variable and y being a continuous variable I get a box plot. If I do the same but y being another categorical variable I get some weird bar plot (figure below). How do you interpret this king of plot?

plot you get when plotting a categorical variable against another categorical variable

In this plot,x (df$category1) has 13 levels:

[1] "A" "B" "C" "D" "cluster1" "cluster5"
[7] "cluster2" "cluster8" "cluster0" "cluster6" "cluster4" "cluster3"
[13] "cluster7"

and y (df$category2) has only 12 levels :

[1] "A" "B" "C" "D" "cluster5" "cluster0"
[7] "cluster4" "cluster2" "cluster3" "cluster6" "cluster1" "cluster7"

A, B, C, and D are the same between the two columns, the rest if clusters are not necessarily the same as are the result of different clustering runs.

Edit : the code used was plot(df$category1, df$category2)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T18:55:18+00:00Added an answer on May 28, 2026 at 6:55 pm

    When x and y are both factors, plot calls spineplot. Example from that function’s help page:

    treatment <- factor(rep(c(1, 2), c(43, 41)), levels = c(1, 2),
        labels = c("placebo", "treated"))
    improved <- factor(rep(c(1, 2, 3, 1, 2, 3), c(29, 7, 7, 13, 7, 21)),
        levels = c(1, 2, 3),
        labels = c("none", "some", "marked"))
    
    spineplot(improved, treatment)
    

    Though this looks a little different to the plot you have.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

My problem is I am comparing two records from different tables and deleting those
C# I'm trying to compare two different objects (I'm only comparing identical subfields). But
When comparing two strings how to avoid checking if a string is of different
I am comparing results of two different JDBC drivers of oracle with the help
I would like to compare different PHP code to know which one would be
I am looking for some relatively simple data sets for testing and comparing different
I want to compare the pixel of the two different images. I am comparing
I've got some code that relies on comparing two NSIndexPaths and executing different code
I'm looking for a elaborate list comparing different operations in PHP. For example: echo
Are there techniques for comparing the same data stored in different schemas? The situation

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.