You are on page 1of 4

Factor Analysis

STI165004

24/07/2021

factor_data=read.csv("C:/Users/mijrh/OneDrive/Documents/Factor Data.csv",
header = T,
row.names = 1)
head(factor_data)

## Leave.your.skin..really.soft.and.smooth
## Nov’07 62
## Dec’07 65
## Jan’08 67
## Feb’08 69
## Mar’08 64
## Apr’08 66
## Moisturise.your.skin.better.than.other.brands
## Nov’07 56
## Dec’07 54
## Jan’08 56
## Feb’08 60
## Mar’08 54
## Apr’08 58
## Make.you.look.and.feel.beautiful
## Nov’07 52
## Dec’07 54
## Jan’08 57
## Feb’08 59
## Mar’08 60
## Apr’08 61
## Are.brands.you.trust.more.than.other.brands Are.the.experts.in.skincare
## Nov’07 58 69
## Dec’07 59 71
## Jan’08 61 70
## Feb’08 64 66
## Mar’08 58 66
## Apr’08 60 69
## Contain.natural.ingredients Fight.the.ageing.process.effectively
## Nov’07 38 55
## Dec’07 37 58
## Jan’08 36 60
## Feb’08 40 62
## Mar’08 30 57
## Apr’08 36 60
## Are.modern.up.to.date Give.you.glowing.skin

1
## Nov’07 70 50
## Dec’07 66 56
## Jan’08 64 60
## Feb’08 70 60
## Mar’08 66 60
## Apr’08 64 60
## Effectively.make.your.skin.fairer...lighter
## Nov’07 57
## Dec’07 63
## Jan’08 65
## Feb’08 67
## Mar’08 62
## Apr’08 63
## Control.skin.breakouts.effectively Control.oily.skin.effectively
## Nov’07 56 53
## Dec’07 59 55
## Jan’08 59 58
## Feb’08 58 55
## Mar’08 53 49
## Apr’08 58 53
## Are.enjoyable.to.use Are.more.gentle.and.mild.than.other.brands
## Nov’07 54 58
## Dec’07 53 54
## Jan’08 59 59
## Feb’08 62 59
## Mar’08 58 52
## Apr’08 61 58
## Makes.your.skin.look.and.feel.fresh Put.a.little.romance.into.things
## Nov’07 48 56
## Dec’07 53 55
## Jan’08 57 58
## Feb’08 57 58
## Mar’08 55 49
## Apr’08 54 57
## Are.feminine.in.how.they.look.and.talk Removes.spots.and.blemishes
## Nov’07 50 0
## Dec’07 57 0
## Jan’08 59 0
## Feb’08 60 0
## Mar’08 50 0
## Apr’08 58 0
## Makes.my.skin.tone.even
## Nov’07 0
## Dec’07 0
## Jan’08 0
## Feb’08 0
## Mar’08 0
## Apr’08 0

pcf=princomp(factor_data)
summary(pcf)

## Importance of components:
## Comp.1 Comp.2 Comp.3 Comp.4

2
## Standard deviation 42.4202759 8.44429422 3.995912498 3.682127407
## Proportion of Variance 0.9222146 0.03654363 0.008183083 0.006948365
## Cumulative Proportion 0.9222146 0.95875822 0.966941305 0.973889670
## Comp.5 Comp.6 Comp.7 Comp.8
## Standard deviation 2.815262798 2.600081491 2.492505554 2.381558360
## Proportion of Variance 0.004061841 0.003464647 0.003183884 0.002906749
## Cumulative Proportion 0.977951511 0.981416157 0.984600042 0.987506790
## Comp.9 Comp.10 Comp.11 Comp.12
## Standard deviation 2.155352883 1.955805014 1.775407309 1.68364277
## Proportion of Variance 0.002380794 0.001960361 0.001615403 0.00145273
## Cumulative Proportion 0.989887584 0.991847945 0.993463349 0.99491608
## Comp.13 Comp.14 Comp.15 Comp.16
## Standard deviation 1.576087932 1.49167659 1.341062396 1.0939169183
## Proportion of Variance 0.001273051 0.00114034 0.000921686 0.0006132728
## Cumulative Proportion 0.996189130 0.99732947 0.998251156 0.9988644288
## Comp.17 Comp.18 Comp.19
## Standard deviation 1.0820778599 0.7716600411 0.6704044182
## Proportion of Variance 0.0006000702 0.0003051666 0.0002303344
## Cumulative Proportion 0.9994644990 0.9997696656 1.0000000000

screeplot(pcf)

pcf
1500
Variances

1000
500
0

Comp.1 Comp.3 Comp.5 Comp.7 Comp.9

fact <- factanal(factor_data, factors=1, scores = c("regression"), rotation = "varimax")

#Obtaining the factor loadings of the given data

3
fact$loadings

##
## Loadings:
## Factor1
## Leave.your.skin..really.soft.and.smooth 0.571
## Moisturise.your.skin.better.than.other.brands 0.792
## Make.you.look.and.feel.beautiful 0.611
## Are.brands.you.trust.more.than.other.brands 0.756
## Are.the.experts.in.skincare 0.567
## Contain.natural.ingredients 0.833
## Fight.the.ageing.process.effectively 0.596
## Are.modern.up.to.date 0.571
## Give.you.glowing.skin 0.785
## Effectively.make.your.skin.fairer...lighter 0.655
## Control.skin.breakouts.effectively 0.807
## Control.oily.skin.effectively 0.870
## Are.enjoyable.to.use 0.776
## Are.more.gentle.and.mild.than.other.brands 0.813
## Makes.your.skin.look.and.feel.fresh 0.818
## Put.a.little.romance.into.things 0.801
## Are.feminine.in.how.they.look.and.talk 0.699
## Removes.spots.and.blemishes 0.722
## Makes.my.skin.tone.even 0.715
##
## Factor1
## SS loadings 10.145
## Proportion Var 0.534

You might also like