Information of the user in comments I want to show the information of the author in his comment. By default it shows the name and the picture, I want to add: 


The number of node and created comments
The number of obtained userpoints. 


What code should I use to achieve this?
Each comment runs through comment.tpl.php template, where the php variables are replaced with actual values and from where you get the actual html

Before going to tpl files, execution passes through template_preproces functions, preprocess function allows you to add new variables or override existing variables which you use on tpl files.

Now in your case it is comment.tpl.php, if you see the file in bartik theme the code 

  &lt;div class="attribution"&gt;

    &lt;?php print $picture; ?&gt;

    &lt;div class="submitted"&gt;
      &lt;p class="commenter-name"&gt;
        &lt;?php print $author; ?&gt;
      &lt;/p&gt;
      &lt;p class="comment-time"&gt;
        &lt;?php print $created; ?&gt;
      &lt;/p&gt;
      &lt;p class="comment-permalink"&gt;
        &lt;?php print $permalink; ?&gt;
      &lt;/p&gt;
    &lt;/div&gt;
  &lt;/div&gt;


is responsible to show comment author information. In order to override the html you can simply copy the comment.tpl.php from parent theme to your base theme and start overriding the html. If you want to introduce new variable to the template, then use template_preprocess_comment(), for example on your theme template.php

function your_theme_preprocess_comment(&amp;$variables) {
  // To Debug what is inside variables already
  dpm($variables);
  // To override exisiting variable
  $variables['author'] = 'my test author';
  // To add any new variable to comment.tpl.php
  $variables['author_comment_count'] = _some_function_fetch_comments_count($user_id);
  $variables['author_nodes_count'] = _some_function_fetch_node_count($user_id);
  $variables['author_user_points'] = _some_function_fetch_user_points($user_id);
}


Now you will have three more variables to use on comment.tpl.php as
$author_comment_count, $author_node_count, $author_user_points

Use them on template, example

&lt;div class="attribution"&gt;

    &lt;?php print $picture; ?&gt;

    &lt;div class="submitted"&gt;
      &lt;p class="commenter-name"&gt;
        &lt;?php print $author; ?&gt;
      &lt;/p&gt;
      &lt;p class="comment-time"&gt;
        &lt;?php print $created; ?&gt;
      &lt;/p&gt;
      &lt;p class="comment-permalink"&gt;
        &lt;?php print $permalink; ?&gt;
      &lt;/p&gt;
      &lt;p class="comment-count"&gt;
        &lt;?php print $author_comment_count; ?&gt;
      &lt;/p&gt;
      &lt;p class="node_count"&gt;
        &lt;?php print $author_node_count; ?&gt;
      &lt;/p&gt;
      &lt;p class="user-points"&gt;
        &lt;?php print $author_user_points; ?&gt;
      &lt;/p&gt;
    &lt;/div&gt;
  &lt;/div&gt;