Wednesday, February 10, 2016

Why do I use R ?

Last two years I've been learning R and using it in my everyday work. And As much as It has been a change of mindset. I'm really happy with it. Much of my work about data clean up has been automated. And all the packages created by the community make my life easier.

Here is a little list of the things I like the most

  1. Unlike SPSS or SAS it's open source
  2. It's a full programing language
  3. Has a nice graphical toolset
  4. It's platform independant (Yeap I just use windows at work, but who cares)
  5. It has a lot of analysis and data manipulation tools
  6. Did I mention is open source ?
  7. A helpfull community
  8. It's been growing in popularity the last 5 years not only in the studies field but as a real world work tool
  9. And most of all...It's free as in speech, so everybody can recreate anything. And help solving stuff

I tested a bunch of IDEs and I love this one Rstudio. This one is free as in "free beer"
It has all the features I need and more.

Thursday, January 14, 2016

My vim setup

My VIM


First entry after a long time....

Every time I take over a new linux machine and I want to create some scripts is to setup my enviroment. And as retrograde as I am, I love VIM as long as its not a java development, in that case My weapon of choice is eclipse.... Anyways, this is my reminder not to loose much time looking for git repositories and stuff.. ( This week alone I've had to change two laptops because of different reasons ).

As I love easy setup things I just go and Install Vundle plugin
  1. git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
Copy my .vimrc to the ~/.vimrc
set nocompatible
filetype off

set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()

Plugin 'VundleVim/Vundle.vim'
Plugin 'tpope/vim-fugitive'
Plugin 'SirVer/ultisnips'
Plugin 'honza/vim-snippets'
Plugin 'flazz/vim-colorschemes'
Plugin 'bling/vim-airline'
Plugin 'henrik/vim-ruby-runner'
Plugin 'kchmck/vim-coffee-script'
Plugin 'scrooloose/nerdtree'
Plugin 'scrooloose/syntastic'
Plugin 'tpope/vim-abolish'
Plugin 'tpope/vim-endwise'
Plugin 'tpope/vim-rails'
Plugin 'vim-ruby/vim-ruby'
Plugin 'Valloric/YouCompleteMe'

call vundle#end()
filetype plugin indent on

" ┌───────────────────────────────────┐
" │       Plugins customizations      │
" └───────────────────────────────────┘
"
" NERDTree
nmap  :NERDTreeToggle

let g:UltiSnipsExpandTrigger=""
let g:UltiSnipsJumpForwardTrigger=""
let g:UltiSnipsJumpBackwardTrigger=""
let g:UltiSnipsEditSplit="vertical"


" vim-airline
set laststatus=2
let g:airline_powerline_fonts = 1
set t_Co=256
"
" " ┌───────────────────────────────────┐
" " │             Settings              │
" " └───────────────────────────────────┘
"
" " Completion
autocmd FileType ruby,eruby set omnifunc=rubycomplete#Complete
autocmd FileType python     set omnifunc=pythoncomplete#Complete
autocmd FileType javascript set omnifunc=javascriptcomplete#CompleteJS
autocmd FileType html       set omnifunc=htmlcomplete#CompleteTags
autocmd FileType css        set omnifunc=csscomplete#CompleteCSS
autocmd FileType xml        set omnifunc=xmlcomplete#CompleteTags
autocmd FileType php        set omnifunc=phpcomplete#CompletePHP
autocmd FileType c          set omnifunc=ccomplete#Complete

autocmd FileType ruby,eruby let g:rubycomplete_buffer_loading = 1
autocmd FileType ruby,eruby let g:rubycomplete_rails = 1
autocmd FileType ruby,eruby let g:rubycomplete_classes_in_global = 1

"let g:SuperTabDefaultCompletitionType = ""
let g:SuperTabDefaultCompletionType = "context"

" Autoindent with two spaces, always expand tabs
set tabstop=2
set shiftwidth=2
set expandtab

" Folding settings
set nofoldenable
set wildmode=list:longest " make cmdline tab completion similar to bash
set wildmenu " enable ctrl-n and ctrl-p to scroll thru matches
set wildignore=*.o,*.obj,*~ " stuff to ignore when tab completing

" Vertical / horizontal scroll off settings
set scrolloff=3
set sidescrolloff=7
set sidescroll=1


" Ignore case in searches
set ignorecase

set splitright
set splitbelow
set nobackup
set noswapfile


let g:syntastic_javascript_checkers = ['jshint']
let g:syntastic_html_tidy_ignore_errors=[" proprietary attribute \"ng-"]
let g:syntastic_mode_map={ 'mode': 'active',
                         \ 'active_filetypes': ['ruby', 'javascript'],
                         \ 'passive_filetypes': ['html'] }

" ┌───────────────────────────────────┐
" │               Theme               │
" └───────────────────────────────────┘

" Fonts for Linux
set guifont=Bitstream\ Vera\ Sans\ Mono\ 9
" set guifont=Monospace\ 10


" Don't show the top bar
" iset guioptions-=T

" Syntax on
syntax enable
colorscheme summerfruit256

if has("gui_running")
  set lines=57
  set columns=237

  " Highlight the line and the column of the current position of cursor
  set cursorline
"  set cursorcolumn
  hi CursorLine guibg=#FFFF66
"  hi CursorColumn guibg=#222222
endif


For one of the plugins [Valloric/YouCompleteme]. You need to compile some libs therefore you need to make sure you have the python developer libs 
In Ubuntu it will be: sudo apt-get install python-dev




Monday, July 07, 2008

Asegurando Web Services con WSE 3 & VS2008 (Parte I )


Hay algo que tengo que decir de entrada y es ........ Por que tiene que ser tan dificil!!!
acabo de oir un webcast que dice que es sencillo, quizas deberia comenzar a pensar en WSE for dummys o algo asi.. bueno
Detallo mis impresiones paso a paso, espero le ayuden a alguien....



  • Alto nivel de abstracción. Ok, puedo vivir con esto, no deberia conocer todos los detalles para poder usarlo, no debe ser problema, un buen nivel en la curva de aprendizaje, pero luego todo ira smooth.

  • Ok, trae ejemplos de los escenarios, excelente, no tengo que internetear mucho alli estan, bien comentariados, otro buen punto

  • Wow, trae exactamente el ejemplo que necesito, WSE + Certificados digitales para firmarlos, parece que esto sera facil

  • Mmmm, aparentemente hay dos versiones del instalador, la version de distribucion y la version de desarrollador, lastimosamente como todo buen sitio que representa recursos para programadores, aparentemente no se querian quedar atras de SUM MS. Asi que el sitio es lo suficientemente confuso, para que termines bajando el que no es y ensucies la instalacion ... entonces, recomendacion , siempre bajar el paquete MAS GRANDE

  • OK, deberian aparecer algunas herramientas graficas... que raro, en los tutoriales siempre hay herramientas graficas.. nuevamente, dato interesante .... los Addons solo funcionan en VS2005 .... que bien. Solamente para agregar al dato,

  • Bien, creemos un certificado para poder comenzar... ugh O_O este, donde esta la herramienta para crear los certificados .... si tienes instalados solamente VS2003 y 2008, seguramente, como yo, tendras una version desactualizada del comando makecert.exe , basta y sobra decir, que mejor baja uno mas actualizado, ya que la opcion de exportacion
    -sky exchange
    OK, no busques mas, si utilizas el prompt que utiliza VS2008, tendras en tus variables de entorno, una version util, sino, puedes buscarla en:
    C:\Archivos de programa\Microsoft Visual Studio 9.0\SmartDevices\SDK\SDKTools



Problemas que podriamos encontrar hasta aqui... simplemente caer en la tentacion
  • Este es un punto muy importante.. NO, repito, NO, intentes administrar los permisos o mover los certificados utilizando la consola de management de windows mmc. Si mueves un certificado alli, por alguna razon que desconozco, pero que tiene que ver con el archivo fisico original, luego de moverla, en su nueva localidad, no importa que permisos se le asignen, jamas, de los jamases, podras ejecutar la llave privada del certificado (seran issues de seguridad o simplemente M$ jugando con mi mente )

  • El punto anterior, es el que deriva en un mensaje criptico o mas bien muy generico, que nos dice solamente que el uxuario xxx/xxx no posee privilegios suficientes para poder acceder a la llave privada o al certificado dentro del repositorio especificado... NO WAY, luego de ver el big NO NO de arriba, podran darse cuenta que es muy facil caer en este problema, en lo personal, me tomo 2 dias caer en la cuenta que por mas que asignara permisos, si agregaba el certificado de esta manera, no habia vuelta atras.

  • Otro dato interesante, es que si al agregar el certificado, desde la consola de management (mmc) lo agregamos directamente a la llave de la maquina, y luego queremos
    cambiar los permisos..... OH sorpresa, me dejo agregarlo, pero, no puedo cambiar los permisos de lectura sobre la llave privada, por ende, nadie lo puede utilizar ... weird verdad

En la siguiente entrega, agregaremos los comandos para poder crear el certificado,
como agregarlo al repositorio y agregar los permisos... No, no tiene herramienta grafica, observamos un Setup.bat en el directorio raiz, de los ejemplos que vienen con el WSE... pues, tendremos que ponerle un poco de atencion a este....