Appropriate Test for Binary Dependent Variable and Continuous Independent Variable I have a dataset of observations of hawks foraging. I am trying to examine the relationship between height of perch used (continuous independent variable, integers of 0 through 10) and outcome of a foraging attempt (binary: success or fail). I'd like to answer the question, are hawks more successful at shorter or taller perches.
Would it be appropriate to use a linear regression or is there something more apropos?
 A: Your outcome of interest is the success probability of success. Therefore, you want some kind of probability model that estimates the probability of a success for a given perch height.
Linear regression in this case would be a linear probability model. While people do use this, there are issues, among them being that illegal probabilities exceeding $1$ or below $0$ can be predicted.
More reasonable might be a logistic regression, which applies a clever transformation to your predictions to squeeze them into legal probability values.
Any decent statistical software will have a logistic regression option that outputs coefficient estimates along with confidence intervals and p-values. You interpret the coefficients similar to how you would interpret them in a linear regression, except that they explicitly describe changes in log-odds. Simplified, this means that a positive coefficient corresponds to an increase in probability while a negative coefficient corresponds to a decrease in probability.
You do have to watch out for how you code your binary variable. Typical would be to take failures as $0$ and successes as $1$. If you do not do this coding explicitly and rely on your software to interpret a string input, you will want to know how that conversion occurs.
A: Can you reframe your question as, "Are perch heights different between successful and unsuccessful foraging attempts?"  In this case, you could compare the two groups, success and failure, with a t-test.  By using a two-tailed t-test, you are making no assumptions of the direction of the difference, higher or lower could either be more successful.
The null hypothesis in this case is that heights do not differ between successful and failed foraging attempts, and the alternative hypothesis that perch height does differ between groups.
