Showing posts with label analysis. Show all posts
Showing posts with label analysis. Show all posts

Thursday, December 2, 2010

Logistic regression analysis - Introduction to the role and Logit odds ratio

Researchers are also studying the structure of a model on the relationship between the predictors (ie, independent variables) and response (ie dependent variable). linear regression is often used when the response variable is continuous. An assumption of linear models is that the residuals follow a normal distribution. This assumption fails if the response variable is categorical, then a normal linear model is not appropriate. This article presents a. regression model of a variable, the answer is often with two dichotomous categories of examples: if a plant lives or dies, if accepted by a respondent or contradicts a statement, or if a child graduates or leaves school risk.

In the town of linear regression is the response variable (Y) is a linear function of the coefficients (B0, B1, etc.), equivalent to the predictor variables (X1, X2, etc.). A typical model lookas follows:

Y = B0 + B1 * X1 + B2 * X2 + B3 * X3 + ... + E

For a dichotomous response variable, we could use a similar linear model to predict individual membership category, if the numerical values are used to represent the two categories. Any value of 1 and 0 chosen for mathematical convenience. The first example, we assign Y = 1 if a plant alive and Y = 0 when the plant dies.

The linear model is not working wellfor some reasons. First, the response values 0 and 1 are arbitrary, the modeling of the actual values of Y is not very interesting. Secondly, it really is the probability that each individual in the population with 0 or 1, we are interested in answer modeling. For example, we plant with a high degree of fungal infection (X1) fall into the category of "life plan" (Y) less frequently than plants with low levels of infection detected. Just as the level of infection is increasing,survival of a plant decreases.

This, we model P, the probability to take into account the response variable. Again, there are problems. Despite the general decrease in the probability of a generalized increase in the rate of infection is associated, we know that P, like all the odds may be within the limits of 0 and 1. Therefore, it is better to accept that the relationship between X1 and sigma P (S-shaped), rather than a scaleLine.

However, you can work in a linear relationship between X1 and function of P. Although a number of functions, one of the most useful finding is the logit function. It 's the natural logarithm of the probability that Y equals 1, which is simply the ratio between the probability that Y 1 divided by the probability that Y is 0. The relationship between the logit of P and P itself is shaped sigmoid. The resulting regression equationis:

ln [P / (1-P)] = B0 + B1 * X1 + B2 * X2 + ...

Although the left side of this equation looks intimidating, in this way, the probability that the right side of the equation is linear and look familiar to us. This helps us to understand the significance of regression coefficients. The coefficients can be changed slightly so that its interpretation makes sense.

The logistic regression equation can be extendedcase of dichotomous variables on the response of groups and categories polytymous ordered (more than two categories).

Wednesday, December 1, 2010

logistic regression analysis - understanding odds and probability

to measure the probability and the same probability: the probability of a given result. People use the terms interchangeably possibilities and the chances of a casual use, but this is regrettable. It only creates confusion, because they are not equivalent. They measure the same thing on different scales. Imagine how confusing it would be if people used interchangeably Celsius and Fahrenheit. "There will be 35 degrees today" might actually wear the wrong way.

Remember meback to your introductory course in statistics back to all these problems on the probability of drawing red balls and white balls from an urn. In these problems, the probability of drawing a red ball is measured by how many balls there were in total and how many were red.

In measuring the probability of a result, we need to know two things: how many times something happened and how often it could happen. The result of interest is a success, if it is a good result orno.

The other exit is a failure. Every time you encounter the results is a process called. Since each process in the success or failure, the number of successes and failures in the number of total order must be based on the total number of attempts.

Probability of success is the number the total number of attempts has occurred with respect.

Chances are the number of successes has been the number of errors occurred in the comparison.

For example, the likelihood of accidents in a forecastparticular intersection, every vehicle that is going through an intersection as an attempt. Each study is one of two results: pass or accident. If the result we are most interested in the modeling of an incident that happened (no matter how it sounds morbid) is.

Probability (success) = number of successes / total number of units attempted (success) = number of successes / number of failures

The odds are often written as:

Number of successes: 1 failures

Read 'Number of hits for all faults 1. But often, one will be deleted.

I see a lot of learning when the researchers blocked logistic regression because they are not accustomed to thinking about the risk of a bet are standard.

Equal opportunities are a first success for every failure 1. 01:01 equal probability .5. A success for all the 2 studies.

The odds are infinity to 0. Odds greater than 1 indicates success rather than failure. Rates of less than 1 indicates the failure is more likely toSuccess.

Probability can range from 0 to 1-area. probability greater than 0.5 indicates success rather than failure. less than 0.5 indicates an error probability is more likely to be a success.

Example: In the last month, shows data from a particular intersection, a .354 that the car drove by him, 72 it was an accident.

72, 1282 incident = = Errors Safe Passage (1354-1372) Total Error = - Pr happened (accident) = 72/1354 = 0.053 Pr (Safe Passage)= 0.947 = 1282/1354 Odds (accident) = 72/1282 = 0.056 Odds (Security) = 1282/72 = 17.87

Now you get the computer because you will see how these relate to each other.

Odds (accident) = Pr (accident) / Pr (security) Odds (accident) = (72/1354) / (1282/1354) = 0.056 (the denominator cancel) Odds (accident) = 1/Odds (Safe Passage) = 1/17.87

Tuesday, November 30, 2010

Plan your data analysis in 3 steps

Back when I was doing research in psychology, one of my biggest challenges has been enough data. And while these rates are probably still do for many experimental researchers with the ability of the Internet to access data, it appears that the data faster than rabbits reproduce.

Now I see a lot of research on the comparison with the administration and analysis of vast amounts of data to be overcome.

Even a moderate number of variables can lead to endless variations on the analysis. "Hmm, I wonder if thestem length is correlated with the wind direction. What is the measure of plant size, leaf area? And 'this correlates with the direction of the wind? "This can go on forever.

According to Frank Scarpaci, owner of Design Works Project, there is a

"1:10:100 rule:
Every dollar of planning and preparation will save $ 10 or $ 100 is project work to solve problems after the project. "

And as in science, time is money (or even more valuable) Planning StatisticsThe analysis saves time and endless frustration. I mean, you think better for an hour now the analysis as a "once in a year after the auditors rip to shreds, right?

The best time for planning the analysis is to collect data as before. This prevents the (all too common) situations where one has understood, requires a different variable, or if you have something measured on a different scale. Grant applications force you to do this, but would benefit in each study.

How do you wantReally? They are based on the results, we report. You should already know the questions to be answered in this study, but written with it in a list will keep you on track. It was not necessary (and should) respond to any questions that the data in this study.

I found a great place for a simple analysis of the plan is a brilliant article by Darryl Bem newspaper articles written about writing. The article is very good (and I highly recommend), but the most usefulPlanning is the section "Presentation of the results." This section outlines seven steps for reporting the findings. For planning, I condense these three:

1. State of the conceptual assumptions Ask
2. To formulate this hypothesis in terms of variables that measure the concept
3. List of statistical test or method to answer this question

Just repeat together to answer these three phases for all the hypotheses of the study. Start with the general andimportant, and work down from there.

Do these three steps before sitting down to analyze three advantages:

1. It forces you, the variables, use the selection. The election at the beginning you can bring unwanted variables from large data sets, time in a much faster processing. It defines the variables to make the univariate analysis, and clearly defined which variables to collect.
2. It is frightening is irrelevant analysis of implementation, which saves time, energy,and frustration as well as your article clearly and logically.
3. It makes the results in writing a children's section.

It 'true that there is a place for exploratory data analysis and some surprises, there are still pop-up data, a trend unexpected, and so on. But again and again on the track is always easier when the direction in which you are going to know.

For more information, see:

Bem, D. (2003). "Writing the Empirical Journal Article". In The CompleatAcademic: a practical guide for the beginning social scientist, 2 Edition. Darley, JM, Zanna, MP and Roediger III, HL (Eds.), Washington, DC: American Psychological Association.

Monday, November 1, 2010

The linear regression analysis - Interpreting the interactions between continuous and categorical predictors

In linear regression, the interaction terms add significantly to the understanding of the relationship between the variables of the model allows multiple hypotheses to be tested. The disadvantage is that it is more difficult to interpret the regression parameters. This article describes how to interpret the estimates of regression parameters when there is a pattern of interaction.

The example is a model of the height of a shrub (height) by the amount of bacteria in the soil(Bacteria) and that the shrub is in part or in full sun (sun). The height is measured in cm, is measured in thousands of bacteria per ml of the Earth and Sun = 0, if the plant part, Sun and Sun = 1 if the plant in full sun. The regression equation was estimated as follows:

Height = 42 + 11 + 2.3 * Bacteria * Sun

It would be useful to add an interaction term of the model, if we wanted to test the hypothesis that the relationship between the amount of bacteria in the soil on whichHeight of the spot was different from that in full sun to part so One possibility is that in full sun, plants with more bacteria in the soil are greater, while in partial sun, plants are shorter with more bacteria in the soil, tend. Another possibility is that plants are more bacteria in the soil is greater than in either total or partial tend Sun, but that the relationship is much more dramatic in the middle part so

The presence of a significant interaction shows that theEffect of a predictor of target size is different at different values of the other predictor variable. It will be multiplied by adding a term of the model in which the two predictor variables tested. The regression equation will look like this:

Height = B0 + B1 + B2 + B3 * Bacteria * Sun * Sun * bacteria

Adding an interaction term, a model radically changed the interpretation of all coefficients. If there were no interaction term could be interpreted as B1,the only effect of bacteria on the size. Since the interaction indicates that the effect of bacteria on the top to different values of the Sun, the only effect of bacteria on height is not limited to B1, but it also depends on the values of so B1 and B3 + B3 * Sun: L ' unique effect of all bacteria is represented by bacteria that multiply in the model. B1 can now only as the effect of bacteria on height only if Sun can be interpreted = 0.

In our example, if you addConcept of interaction provides for our model as follows:

Height = 35 + 9 + 4.2 * 3.2 * + * Sun Bacteria Bacteria Sun

Note that adding the interaction term changes the values of B1 and B2. The effect of the bacteria level is now 4.2 + 3.2 * in the case of plants in partial sun, Sun = 0, so that the effect of bacteria is 4.2 + 3.2 * 0 = 4.2. So for two plants in partial sun, a plant with more than 1000 bacteria / ml in the world would probably be 4.2 cm greater than a plant with less bacteria. For plantsfull sun, but the effect of bacteria 4.2 + 3.2 * 1 = 7.4. So for two plants in full sun, a plant with more than 1000 bacteria / ml in the world would probably be 7.4 cm greater than a plant with less bacteria.

Because of the interactions, the effect is more bacteria in the soil in a different way, when a plant has been said, in whole or in part, so different that the slope of the regression between height and number of bacteria are different for different categories ofSun B3 shows how different the tracks.

B2 interpretation is more difficult. B2 is the effect of the sun, when the bacteria = 0. Since the bacteria is a continuous variable, it is unlikely that 0 is the same, if nothing else, B2, virtually meaningless in itself. Instead, it is useful to understand the effects of the sun, but again, this can be difficult. The effect of the sun is B2 + B3 * Bacteria, which is different for each of the infinite values of bacteria. For this reason, oftenThe only way is to get an intuitive understanding of the effects of the sun, some levels of bacteria in the plug equation, such as altitude, the target size to see the changes.