wokring version of dinamic update of chart from user input