Principal Components Analysis in R

Principal Components are really useful for dataset with a large number of variables that potentially are correlated between them. By creating vectors using the variables, we reduce the number of ‘variables’ to be included in the model. The aim is to include the components that explain the larger volume of variation of the dataset.

How to do Principal Components Analysis using R?

Initially, we need data so let’s go to create:

x1<- c(122, 21, 105, 101, 155, 131, 115, 53, 75, 45)
x2<-c(117, 32, 140, 105, 149, 146, 82, 60, 82, 37)

The we will scale it with:

Read more

VBA Create a Parabola

Excel allows creating programs using VBA (Visual Basic Applications).

This program shows how to create a parabola witb VBA:

Private Sub CmdBotton_Click()
Dim dblB As Double
Dim dblH As Double

‘User introduce values
dblB = InputBox(“please introduce a value for Base”, “Base Value”)
dblH = InputBox(“please introduce a value for Height”, “Height Value”)

‘Output value to Excel sheet
Range(“D17”).Value = dblH
Range(“D16”).Value = dblB

Read more

Marketing Board on Pinterest: Don’t say it with words

Content Marketing has been rising for the last five years. Internet users (we) don’t want to be told what to do, we want information available in order to choose ‘the best’ option for us.

But what happen when there is too much information? Too much content?

Studies reported that the attention span is decreasing:

“Our Average Attention Span Is Now Shorter Than Goldfish”

Right… fish according SAP Business

For this reason it is normal that Marketing is looking for something more… catchy?

Well, I could write thousand of words here but I am better leaving you with my ‘Marketing Board’ on Pinterest:

Follow Silvia’s board Marketing on Pinterest.

Sentiment Analysis, Twitter and R

Within the Data Science and Analytic Higher Diploma, I have been asked:

“Research an area of sentiment analysis that is of interest to you. Describe the process that is required to implement the analysis and how you would do this.”

So I through myself to research using ‘Google’ some information about Sentiment Analysis and I found this Youtube video that explains how to use R and Twitter to do some Sentiment Analysis.

Personally I think Michael Herman did a fair job with this video; however, it was published on 2012 – therefore with different changes going on in Youtube and new R versions, the code provided show various errors.

So, after playing around with the code provided in the video and doing some searches I successfully analysed some data.

Here is my R code for the Sentiment Analysis proposed by Michael: Read more