Asking for help¶
A common issue for people new to coding is that they don’t know how to ask for help effectively. This is a normal part of learning any new skill - it takes time to learn what can cause a problem, and the kind of information you need to troubleshoot that problem.
In person this barrier can be quite easy to overcome. You can look at your code with the person helping you, talk through it, and find a solution.
However, you will probably use emails, messages, and forums to ask for help most of the time. So here are some pointers to help you communicate your problem clearly, and in a way that makes it easy for others to help you:
1. Say what you’re trying to do¶
Clearly state the purpose of your code. What are you putting in, and what do you aim to get out?
This may seem like an obvious point, but it is often missed when asking a collaborator or teacher for help. When you’re deep in a project and it’s all you’re thinking about, it might seem odd that your collaborator has forgotten the details of what you’re working on, especially if you’re in regular contact. However, they’re probably working on lots of different things, and feel the same way about their own projects, so a reminder of what you’re working on will always be appreciated.
2. Describe the problem¶
What problem are you encountering?
It could be that you don’t know how to perform a certain task, or you could be getting an error when you run your code. If you get an error message, make sure to include it.
4. Explain how you’ve tried to fix the problem¶
How have you tried to solve it so far? Why do you think your solutions didn’t work?
The first thing you’re likely to do when you get an error is look it up in a manual, or google it. Even if you didn’t quite understand what you found, you’re saving someone else replicating that work if you provide a link to that information.
This also shows that you’ve had a go at fixing the problem. If a question has already been asked and answered on a forum, or a definition of a term you don’t understand comes up as the first google result, people are likely to just give you that link and no more detail. If you can be specific about what you don’t understand, you are more likely to get answers that help you.
6. Give details about the software you’re using¶
This isn’t always applicable - generally we don’t want to know the version of every package you’re using in R.
(But if someone asks, you can check by using sessionInfo()
)
If you’re struggling to use a certain program or package, you should specify which version you’re using, for example Bowtie2 v2.4.2. Sometimes the commands you need to use will vary between versions, or a given version may have a known issue, so this information can be really useful for troubleshooting.
Where to ask for help¶
There are lots of communities online where you can ask for and provide help. If you’re having a problem, someone else has almost definitely been there before you, and might already have asked for the help you need! These include:
Stackoverflow - a programming community with loads of questions and answers.
Biostars - like Stackoverflow, but for more biological questions. How to get raw data, what a certain option in a program means – there is lots of community info here!