www.crosshyou.info

政府統計の総合窓口のデータや、OECDやUCIやのデータを使って、Rの練習をしています。ときどき、読書記録も載せています。

OECD Young self-employed data analysis 3 - Comparing men and women young data. men has higher ration than women.

Photo by RoonZ nl on Unsplash 

www.crosshyou.info

This post is following of above post.

In this post, let's compare men self-employed and women self-employed.
Firstly, I make two vectors, "men" and "women"

Let's see both summary statistics.

men average is 8.4 and women average is 5.7.

Let's check if the both variance are same ot not. I use var.test() function.

p-value is 1.134e-08, which is almost 0. so variance is not same.

Next, let's check if distribution location is same. I use wilcox.test() function.

p-value is less than 2.2e-16, so men and womrn location is not equal.

So far, I know men and women are different characeristics so, it is better to analyze men and women in separate.

I make a new data frame, which has both men and women variables.

Let's see summary() function results.

Now, we see men's avegrage is 9.21 and women's average is 5.73.

Let's check var.test() for if varaince is same or not.

We see small enough p-value, so men variance and women variance is not same.

How about location?

p-value is almost 0, so men and women are different location shift.

I can say, in general men young self-employed ratio is higher than women uoung self-employed ratio.

Let's see scatter plot.

men and women has positive correlation.

That's it. Thank you!

Next post is

 

www.crosshyou.info

 



To read the first post,

 

www.crosshyou.info