Jump to content
We've recently updated our Privacy Statement, available here. ×

Dr.Spotfire, I'm try to make a PCA model in spotfire.I found this code but it doesn't work properly.


saminda roshan

Recommended Posts

I want to make a PCA model. I found a sample code in exchange.ai

But when I excute the code in Spotfire, it gives me an error.

 

Can anyone help me with this matter.

I would really appreciate if you can upload a dxp sample.

 

Thanks!

This is my code

# Assume your incoming DataTable is called "Data"

# Get rid of na's input.data = na.omit(Data)

# Run the PCA

 

data.pca = prcomp(input.data, center=TRUE, scale. = TRUE)

# Collect outputs

Output

Link to comment
Share on other sites

  • 1 month later...

Hi Natasha,

Thanks for your question, the solution will be discussed in the upcoming Dr. Spotfire session. Register here (https://community.spotfire.com/wiki/doctor-spotfire-office-hours).

If you are unable to make it, the sessions will be recorded and available for viewing on TIBCO Dr. Spotfire playlist (https://www.youtube.com/watchv=hGKmTxVcjJ0&list=PLknbq-WaCOiVvyZpLXHOM2...).

Short answer is that you don't need to build PCA from scratch. You can download the free template "Financial Crime Buster Template" from community.spotfire.com/exchange(link). That already contains code to perform PCA. You simply have to replace your data & follow the template instructions to interpret the results.

Link to comment
Share on other sites

  • 1 year later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...