Friday, August 30, 2019

Using colors in science and color blindness

Recently we send to reviewers a paper dealing with graphs. After the first revision we realised that we should have paid some attention to the colors we use, especially because they are meant to convey information (a lot of) to any reader. One over eight people is known to suffer of some color-blind limitation and therefore it is worth to made efforts to get color-blind friendly palettes of colors (yes, it is not just a question of percentages).

This topic has been addressed in various papers Wong [2011]; Johnson and Hertig [2014]; Keene [2015]; Stauffer et al. [2015]; Nuez et al. [2018] and we refer to those papers for the main issues in making a good choice of colors. There are various colorblind types, the three more diffuse ones ;being: protanopia, deuteranopia, or tritanopia Wong [2011] and we have tried to to understand how these people perceive our graphics.
As Rudis et al. [2018] says graphs and drawing must be ”spanning as wide a palette as possible so as to make differences easy to see, perceptually uniform, meaning that values close to each other have similar-appearing colors and values far away ;from each other have more different-appearing colors, consistently across the range of values; robust to colorblindness, so that the above properties hold true for people with common forms of colorblindness, as well as in grey scale printing ..”,
To understand how colors appear to color-blind people, or to our dog, we can use the information in other website, for instance the one by Martin Krizywinsky.
But I suppose you want to use some desktop based software to do your representations. We have a little choice here. I used the web-based software by David Nichols, which can be found here. R-software users can use the VIRIDIS package but also observe that the popular ggplot2 has its own dedicated palettes. I also know for experience that Python matplotlib already does concerned default choices in this field, as apparent from the central figure of this post. Java programmers can browse Contrast-Finder. Finally if you wants just to do-it-yourself, you can read this stack-overflow thread.
If you are interested to maps, you can give a look here.

Now you cannot escape the necessity to do colorblind friendly drawings.

References

Friday, August 23, 2019

What to keep in mind for a Ph.D. interview

We finished yesterday our interviews for selecting the new cohort of PhD students. (In our system we have a call a year, where we select and enroll all the students). So, I am in the best condition to do some comments and give some advise to future applicants. 

The first observation is that we where there to select the “best students” and therefore we were trying to put the applicants in comfortable conditions. * What we did was to ask the applicants to describe themselves and their research proposal and made some questions about their topic. Nothing apparently special.

In front of us we had people of very different ages and maturity: from 24 to 46 years old. People with different motivations and from different countries and continents. And we did not pretend from them the same attitude and skills.  In the younger, we were requiring enthusiasm, an outstanding CV in the studies they had, but we were less demanding on  pretending from them a comprehensive knowledge of literature. In the older we were more tight on analyzing their specific skills and in try to understand if they could complete, and at which level, the tasks implicit in doctoral studies after years spent out of Academia.
To the older, besides having done something, even in the different fields, we were requiring to demonstrate flexibility and attitude to work in group. We were in fact looking for mature personalities (both in the young and the old actually) but, at the same time, trying to avoid those who could not interact positively with the environment they will eventually stick for the future three/four years. 

Concept One: we search for the best fit. In all of our candidate we were looking for appropriate competence and proactivity: but this was a prerequisite. Be sure: excluding some very rare cases which are apparent, for their evident unicity, "we are all equidistant from Nobel prizes" performances. Therefore there are “best” applicants but, among the best, "best fit” applicants. Above all if we think that science is more a team work than matter for lonely nerds.

Concept two: how do you fit and do you really want to fit ? As I told, the applicant who gets the position, eventually has to stick with the environment around and deal with a supervisor. Therefore a suggestion I feel to give is: it is not forbidden to contact your potential supervisor in advance. This does not imply any commitment by anybody but allows to understand better each other. This can also  be functional  to build a successful research proposal, or to understand if you can (or want) fit with that supervisor without be driven crazy later.  Ph.D. studies are demanding for themselves and especially in a competitive environment as our University can be. Maybe, at the end of your conversation, you do not exactly want to do it. However, there is a chance that you love it. Then, go ahed. Ph.D. can be one of the best periods of your life. 

Concept three: professors pretend to know where their sub-discipline is going and what is best looking for. So, please, do not try to challenge too much their beliefs (see also point 1 and 2). 
Instead you can try to understand if their scientific methods combine with yours, and, in case, how you could interpret their work with your skills. 
As I wrote elsewhere,  do not come to me expecting me to be your butler. A good professor can  recognize to be wrong but you will be their PhD student and they is pretending to suggest the way to go along with you on top of their experience and dictating, at least at the beginning, the methods to use. It can be matter of discussion though (that's what PhD work is made of).  However, you have to convince them politely that your (one among many) new perspective is better,  before they changes their.  Besides, keep in mind that a good professor can estimate the effort, pain and costs to pursue the  goal you suggest and you pay attention to what they says about.

A checklist. Going to the matter, we pretend you:
  • to show solid backgrounds (not necessarily erudition) and attitude to learn
  • having an appropriate knowledge of the literature of the subject on which you want to work on;
  • know what your professor does in his research, which tools he uses and so on;
  • show to be able to express "research questions”;
  • show that you that you can be "focused" and can obtain what is needed (papers, softwares, procedures, patents etc) in limited amount of time (three/four years)
Keep in mind that true research is not an application of some tool but is to delineate new challenges first and solve them eventually. Who is not able to understand what a scientific problem is, cannot be a successful researcher and not even a good Ph.D student. 

Finally:
  • be open to acquire and investigate new tools (during your research life, you will be required to evolve them several times) 
Bonus:

Thursday, August 8, 2019

JSWMM essentials

Interest around urban hydrology has been growing steadily during the last years, and recently had the opportunity to be published in large diffusion scientific journals as Nature. For years the mainstream hydrology has mostly dedicated its attention to "natural" catchments, while considering of secondary importance what happens in cities. Now that most of the people live in cities, and humans are clearly a global agent that affects climate and the whole Earth System, urban hydrology start to be seen under a different light. How works hydrology in cities ? And, for my own interests, how to model and eventually design cities' hydrology ?

My starting point is that good tools developed for generic hydrology should work also for cities. However, over the years some tools specialised for cities and captured the attention of the community of researchers that dedicated to it. Among those is EPA SWMM v5.1.
Actually, EPA SWMM is a rainfall-runoff model but its developer added tools for treating cities specifics, excluding,  a real system for designing storm water networks, a.k.a. pluvial sewers.
With the Master Thesis by Daniele Dalla Torre faced this issue to add to SWMM a designing tool, based on a simplified geomorphic unit based approach. In the meanwhile he found reasonable to port most of SWMM to Java and to embed it in OMS v3. Therefore SWMM became JSWMM and it is available at the GEOframe repository JSWMM inherit everything from SWMM and its i/o files can be run as they are in SWMM. JSWMM clone of SWMM has some evolutionary advantage with respect to SWMM (a part from the designing module which is not existing in the original). Inside JSWMM, in fact, any draining area is processed in parallel from the others, using the Net3 algorithms and this parallelism is made without any intervention of the user. Besides, in future, any appropriate module from GEOframe, could be used to estimate the desired element of the hydrological cycle. Including Richards-1d for infiltration or the coming soon 2D de Saint-Venant module.

No manual is actually ready but the draft of his master thesis (in English) can be used to understand JSWMM internals and his dissertation presentation can be used for the same scope.

Material (to be uploaded soon)