HomeNews and blogs hub

Learning to Code from a mentor's perspective

Bookmark this page Bookmarked

Learning to Code from a mentor's perspective

Author(s)
Mario Antonioletti

Mario Antonioletti

Community Officer / Research Software Engineer

Posted on 18 May 2022

Estimated read time: 6 min
Sections in this article
Share on blog/article:
Twitter LinkedIn

Learning to Code from a mentor's perspective

Posted by s.aragon on 18 May 2022 - 11:00am person holding a pen explaining something on paperPhoto by Scott Graham 

By Mario Antonioletti, Learning to Code Mentorship Programme mentor.

I volunteered as a mentor as part of the SSI’s Beyond the Spreadsheet Research Software Camps. I was motivated by the fact that I wanted to set up a similar time-limited mentoring scheme for the Community of Edinburgh RSEs where synergies in domain expertise could be coupled with programming skills, or as part of the Edinburgh Carpentries where people would go back to their day jobs after a Carpentries course to try and apply what they have learned to their own projects/data where they may need a little help to get started and avoiding those inevitable brick walls.

However, although I could always see the benefits to the mentee I found it harder to see how the mentor would benefit from this process? To me, there was always an altruistic aspect to mentoring but were there any other synergies that could be exploited so that other benefits could be accrued to both parties such as a joint publication? Although there were no guarantees that such an outcome could be achieved in such a relatively short collaboration. So I thought I would try the process out and work out whether there were any benefits to a mentor by doing it.

The mentee I was assigned was Dr Yenn Lee from the School of Oriental and African Studies (SOAS) at the University of London who was keen to try and extend her knowledge of R. Dr Lee has already blogged about her experience as a mentee, and I thought it would be interesting to document the process from the mentoring perspective. The process was limited to eight weeks so we set up regular meetings to cover this process - once a week for the eight weeks. We used R which Yenn had some experience with and wanted to improve on, and we also used GitHub to do some mutual development which I think Yenn had not used before. 

Yenn quickly found a focus for our activities – a Guardian article, My students have paid £9,000 and now they think they own me, which was part of a series of articles run by the Guardian under the academic anonymous topic.. This particular article had achieved a much higher set of comments than the articles in the remainder series and Yenn wanted to investigate this further although she had a strong feeling as to why this might be so. 

Thus the first task we set was to see whether we could get a copy of the comments and responses. Easy, I thought, use the rvest (read it as “harvest”) R-package for web scraping and get a copy of the required content except that it proved to not be as easy as I had first thought. I could get the HTML content for the page but where were the comments? It turned out that these were being generated using JavaScript and could not just be downloaded. To cut a long story short, using the chrome developer tools the comments were being downloaded from the Guardian discussion-API. 

After this, things got a little bit easier and then there was the Guardian Open platform, another API, to get metadata and the contents of the articles. Once we had all the data we tried various techniques to look at the data: network analysis as represented in the diagram below, sentiment analysis and topic analysis. Luckily I did not have to reinvent the wheel but used the techniques described in Text Mining with R but applied to our very own Guardian data set.

 

connectivity of comments (orange) and responses (purple) to the Guardian Fig 1. connectivity of comments (orange) and responses
(purple) to the Guardian

 

In practice, our collaboration amounted to Yenn setting tasks and then I would go away until our next meeting to see whether I could resolve them so I learned a lot so I got the challenge of trying to resolve problems and then walk Yenn through the code for solving the problem. We looked at lots of things - network analysis, sentiment analysis, etc so I certainly learned a lot. As a didactic process, I think Yenn saw how things could be done but if she had to extend the code or do things from scratch ,which I’m not sure it would have worked out so well for her. Did Yenn confirm her suspicions as to why the article generated more traffic? Yes and no. She got more evidence but nothing that would prove her strong suspicions insofar that anything can be proved in a social science context. But, in retrospect, we probably could’ve chosen an easier project to introduce her to coding and it’s certainly something that I would urge mentors to bear in mind when choosing a project with their mentees. 

So what can be concluded – was mentoring worth it? Yes, it stretched my skill set, forced me to apply it to a domain I would not have done on my own and my programming language skills became stronger and were challenged by a task-driven set of goals. In this instance, the mentor may have learned more than the mentee which is not necessarily the goal of this process. I do think that Yenn did benefit from the process but it has not necessarily put her in a better place to extend the existing code or start a similar project from scratch. So next time, and there will be a next time (I’m volunteering for the Learning to Code programme at the Research Software Camp: Next Steps in Coding), I need to take more of a didactic approach and be less driven to solve the problems myself. However, to conclude: is mentoring worth trying out? Totally! My next task is to convince people in a position to mentor about how enriching the experience can be.

Share on blog/article:
Twitter LinkedIn