Results 1 to 5 of 5

Math Help - Help interpreting results

  1. #1
    Newbie
    Joined
    Apr 2011
    Posts
    18

    Help interpreting results

    I think I see what is going on, but when I run my results in R I get strange results that cannot be right. I am thrown off by the subscripts. I would like to see what your take is on the write up.

    Help interpreting results-screen-shot-2013-10-20-6.02.30-pm.png

    Help interpreting results-screen-shot-2013-10-20-6.01.45-pm.png


    My interpretation is I have two 32X32 (number teams) systems of the form A*x = b where, for example, b is the historical defensive statistic and each row in A represents the match ups for team k. So in the first step of the algorithm A is filled with 1's and 0's representing the matchup for that season. However, this can only be done per season, but the paper indicates the usage of historical statistics for the system. I am not sure I can use matchup information at that level as every team has faced off if you back far enough meaning A would be filled with 1's and as result, be singular. When I do it this way I end up with negative, so I don't think it is correct.

    I think the subscripts are throwing me off or possible incorrect. Any feedback would be appreciated.

    Thanks

    Any thoughts?




    Follow Math Help Forum on Facebook and Google+

  2. #2
    MHF Contributor
    Joined
    Sep 2012
    From
    Australia
    Posts
    3,696
    Thanks
    619

    Re: Help interpreting results

    Hey Tabby.

    Can you tell us what routines in R you used and the arguments you passed to those routines (i.e. your R code)?
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Newbie
    Joined
    Apr 2011
    Posts
    18

    Re: Help interpreting results

    Here is the R code

    library(MASS)

    W <- X <- matrix(0,nrow=32,ncol=32)
    y <- matrix(wide.off[,34],nrow=32,ncol=1)
    z <- matrix(wide.def[,34],nrow=32,ncol=1)

    max_itr <- 3

    for(n in 1:max_itr) {
    if(n==1) { W <- matrix(ifelse(wide.off[,2:33]=='NaN',0,1),nrow=32,ncol=32)
    } else { W <- as.matrix(sapply(1:32, function(r,c) ifelse(W[r,c]==0,0,def.stat[c]))) }
    sol.svd <- svd(W)
    D <- diag(1/sol.svd$d)
    U <- as.matrix(sol.svd$u[,])
    V <- as.matrix(sol.svd$v[,])
    def.stat <- (V %*% D %*% t(U)) %*% y
    }

    Where the wide.off and wide.df datasets look like:

    Help interpreting results-screen-shot-2013-10-22-6.59.33-pm.png

    The far right column bas the defensive stat in this example. Wide.df would be the opposite.

    I have also used the normal equations to get the multipliers, but the results are the same. The more I look at it seems like an eigenvalue problem where I am solving Ax = v*x where v is constant. That would make more sense since an SVD is recommended and would produced the singular values. As you cant see, I am just using SVD to solve the least squares problem, which seems kind of circuitous....
    Follow Math Help Forum on Facebook and Google+

  4. #4
    MHF Contributor
    Joined
    Sep 2012
    From
    Australia
    Posts
    3,696
    Thanks
    619

    Re: Help interpreting results

    You have several NaN entries in your data set: how do you treat these values in R? Do you exclude them and if so how?
    Follow Math Help Forum on Facebook and Google+

  5. #5
    Newbie
    Joined
    Apr 2011
    Posts
    18

    Re: Help interpreting results

    Well thats where I am confused. The line W <- matrix(ifelse(wide.off[,2:33]=='NaN',0,1),nrow=32,ncol=32)" is coding the matrix 1 when there is a value and 0 otherwise, that is how I understand the algorithm in the paper. I have used the for loops below to code the 'NaN' values zero and leave the numeric values and preform a least squares to derive the coefficients. I get a number of negative values that don't seem correct.

    for(i in 1:32){
    for(j in 1:32){
    W[i,j] <- ifelse(wide.off[i,j+1]=='NaN',0,wide.off[i,j+1])
    X[i,j] <- ifelse(wide.def[i,j+1]=='NaN',0,wide.def[i,j+1])
    }
    }


    Either way, I don't understand the algorithm that is implemented and why SVD / iteration would even be necessary.
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Help interpreting these solutions
    Posted in the Calculus Forum
    Replies: 2
    Last Post: September 7th 2013, 09:11 AM
  2. Interpreting polls
    Posted in the Statistics Forum
    Replies: 1
    Last Post: April 28th 2013, 08:55 AM
  3. Help interpreting this equation
    Posted in the Advanced Algebra Forum
    Replies: 8
    Last Post: April 16th 2012, 08:19 PM
  4. Interpreting Logistic Results
    Posted in the Advanced Statistics Forum
    Replies: 0
    Last Post: August 15th 2009, 04:29 AM
  5. Interpreting Dif EQ
    Posted in the Calculus Forum
    Replies: 0
    Last Post: November 14th 2007, 05:32 PM

Search Tags


/mathhelpforum @mathhelpforum