{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 123,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "/home/alfaceor/Dropbox/PosDoc/IGoR/Thierry/Lightchain_Thierry/Lightchain/IGL/final_parms.txt\n"
     ]
    }
   ],
   "source": [
    "import pygor3 as p3\n",
    "directory = \"/home/alfaceor/Dropbox/PosDoc/IGoR/Thierry/Lightchain_Thierry/Lightchain/IGL/\"\n",
    "flnVanchors = directory + \"V_gene_CDR3_anchors.csv\"\n",
    "flnJanchors = directory + \"J_gene_CDR3_anchors.csv\"\n",
    "fln_model_parms = directory + \"final_parms.txt\"\n",
    "fln_model_marginals = directory + \"final_marginals.txt\"\n",
    "mdl = p3.IgorModel(model_parms_file=fln_model_parms, model_marginals_file=fln_model_marginals)\n",
    "mdl_anchs = p3.IgorAnchors(flnVanchors, flnJanchors)\n",
    "mdl_parms = p3.IgorModel_Parms(model_parms_file=fln_model_parms)\n",
    "mdl_marginals = p3.IgorModel_Marginals(model_marginals_file=fln_model_marginals)\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 124,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>value</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>index</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>D87007|IGLV(I)-20*01|Homo sapiens|P|V-REGION|1...</td>\n",
       "      <td>CAGTTCCTCTATTATGGTAGAGTCTGCTAGTTTCTCTGGCCCAATA...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>D87009|IGLV(I)-38*01|Homo sapiens|P|V-REGION|7...</td>\n",
       "      <td>CAGTCAGGGCTCACTTGGTGGCCTGCACAGTTTGTCTGTGACTAAA...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>X14613|IGLV(I)-42*01|Homo sapiens|P|V-REGION|3...</td>\n",
       "      <td>ATCATGGCTCATCAGGTAACCTGCACCGTCTGTCTGTGGCTAAACC...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>D86996|IGLV(I)-56*01|Homo sapiens|P|V-REGION|1...</td>\n",
       "      <td>TCCACATGGCACTGACAGCCTCTTTCACTGACCAAGCCTCCGGGAC...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>D87022|IGLV(I)-63*01|Homo sapiens|P|V-REGION|1...</td>\n",
       "      <td>CCATCTGCGCTGATTCAGTCACCCTCAGTCCCTGGGGCTCTGGGCC...</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                                    name  \\\n",
       "index                                                      \n",
       "0      D87007|IGLV(I)-20*01|Homo sapiens|P|V-REGION|1...   \n",
       "1      D87009|IGLV(I)-38*01|Homo sapiens|P|V-REGION|7...   \n",
       "2      X14613|IGLV(I)-42*01|Homo sapiens|P|V-REGION|3...   \n",
       "3      D86996|IGLV(I)-56*01|Homo sapiens|P|V-REGION|1...   \n",
       "4      D87022|IGLV(I)-63*01|Homo sapiens|P|V-REGION|1...   \n",
       "\n",
       "                                                   value  \n",
       "index                                                     \n",
       "0      CAGTTCCTCTATTATGGTAGAGTCTGCTAGTTTCTCTGGCCCAATA...  \n",
       "1      CAGTCAGGGCTCACTTGGTGGCCTGCACAGTTTGTCTGTGACTAAA...  \n",
       "2      ATCATGGCTCATCAGGTAACCTGCACCGTCTGTCTGTGGCTAAACC...  \n",
       "3      TCCACATGGCACTGACAGCCTCTTTCACTGACCAAGCCTCCGGGAC...  \n",
       "4      CCATCTGCGCTGATTCAGTCACCCTCAGTCCCTGGGGCTCTGGGCC...  "
      ]
     },
     "execution_count": 124,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "evento = mdl_parms.get_Event('v_choice')  # get_realization_DataFrame()\n",
    "ev_da = evento.get_realization_DataFrame()\n",
    "ev_da.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 126,
   "metadata": {},
   "outputs": [],
   "source": [
    "import pandas as pd')]\n",
    "df_Vanchors = mdl_anchs.df_Vanchors.rename(columns={'gene':'name'})\n",
    "result = pd.merge(ev_da, df_Vanchors, on='name') #, left_index=True, right_index=True, how='inner');\n",
    "new_df = result.drop(columns=['anchor_index'])\n",
    "new_df.tail()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 134,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>anchor_index</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>D86993|IGLV(I)-70*01|Homo sapiens|P|V-REGION|1...</td>\n",
       "      <td>261</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>D87004|IGLV(V)-66*01|Homo sapiens|P|V-REGION|7...</td>\n",
       "      <td>274</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>X71351|IGLV(VI)-22-1*01|Homo sapiens|P|V-REGIO...</td>\n",
       "      <td>259</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>D86994|IGLV(VI)-25-1*01|Homo sapiens|P|V-REGIO...</td>\n",
       "      <td>260</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>Z73653|IGLV1-36*01|Homo sapiens|F|V-REGION|1.....</td>\n",
       "      <td>264</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                                name  anchor_index\n",
       "0  D86993|IGLV(I)-70*01|Homo sapiens|P|V-REGION|1...           261\n",
       "1  D87004|IGLV(V)-66*01|Homo sapiens|P|V-REGION|7...           274\n",
       "2  X71351|IGLV(VI)-22-1*01|Homo sapiens|P|V-REGIO...           259\n",
       "3  D86994|IGLV(VI)-25-1*01|Homo sapiens|P|V-REGIO...           260\n",
       "4  Z73653|IGLV1-36*01|Homo sapiens|F|V-REGION|1.....           264"
      ]
     },
     "execution_count": 134,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df_Vanchors.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 136,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>value</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>index</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>D87007|IGLV(I)-20*01|Homo sapiens|P|V-REGION|1...</td>\n",
       "      <td>CAGTTCCTCTATTATGGTAGAGTCTGCTAGTTTCTCTGGCCCAATA...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>D87009|IGLV(I)-38*01|Homo sapiens|P|V-REGION|7...</td>\n",
       "      <td>CAGTCAGGGCTCACTTGGTGGCCTGCACAGTTTGTCTGTGACTAAA...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>X14613|IGLV(I)-42*01|Homo sapiens|P|V-REGION|3...</td>\n",
       "      <td>ATCATGGCTCATCAGGTAACCTGCACCGTCTGTCTGTGGCTAAACC...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>D86996|IGLV(I)-56*01|Homo sapiens|P|V-REGION|1...</td>\n",
       "      <td>TCCACATGGCACTGACAGCCTCTTTCACTGACCAAGCCTCCGGGAC...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>D87022|IGLV(I)-63*01|Homo sapiens|P|V-REGION|1...</td>\n",
       "      <td>CCATCTGCGCTGATTCAGTCACCCTCAGTCCCTGGGGCTCTGGGCC...</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                                    name  \\\n",
       "index                                                      \n",
       "0      D87007|IGLV(I)-20*01|Homo sapiens|P|V-REGION|1...   \n",
       "1      D87009|IGLV(I)-38*01|Homo sapiens|P|V-REGION|7...   \n",
       "2      X14613|IGLV(I)-42*01|Homo sapiens|P|V-REGION|3...   \n",
       "3      D86996|IGLV(I)-56*01|Homo sapiens|P|V-REGION|1...   \n",
       "4      D87022|IGLV(I)-63*01|Homo sapiens|P|V-REGION|1...   \n",
       "\n",
       "                                                   value  \n",
       "index                                                     \n",
       "0      CAGTTCCTCTATTATGGTAGAGTCTGCTAGTTTCTCTGGCCCAATA...  \n",
       "1      CAGTCAGGGCTCACTTGGTGGCCTGCACAGTTTGTCTGTGACTAAA...  \n",
       "2      ATCATGGCTCATCAGGTAACCTGCACCGTCTGTCTGTGGCTAAACC...  \n",
       "3      TCCACATGGCACTGACAGCCTCTTTCACTGACCAAGCCTCCGGGAC...  \n",
       "4      CCATCTGCGCTGATTCAGTCACCCTCAGTCCCTGGGGCTCTGGGCC...  "
      ]
     },
     "execution_count": 136,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "ev_da.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 131,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>value</th>\n",
       "      <th>anchor_index</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>D86993|IGLV(I)-70*01|Homo sapiens|P|V-REGION|1...</td>\n",
       "      <td>CAGTCTGCGCTGACCCAGGAAGCCTCGGTGTCAGGGACCGTGGGAC...</td>\n",
       "      <td>261</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>D87004|IGLV(V)-66*01|Homo sapiens|P|V-REGION|7...</td>\n",
       "      <td>CAGCCCGTGCCGACTCAGTCGACCTCTGCATCTGCCTCCCTGGGAG...</td>\n",
       "      <td>274</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>X71351|IGLV(VI)-22-1*01|Homo sapiens|P|V-REGIO...</td>\n",
       "      <td>TGACTGCTCTGACTTAGTCTCCCTCCACCTTATGGGCACCTGGCAG...</td>\n",
       "      <td>259</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>D86994|IGLV(VI)-25-1*01|Homo sapiens|P|V-REGIO...</td>\n",
       "      <td>CTGACTGCTCTGACTCAGTCTCCGTCTACCTCATGGACACCTGGCA...</td>\n",
       "      <td>260</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>Z73653|IGLV1-36*01|Homo sapiens|F|V-REGION|1.....</td>\n",
       "      <td>CAGTCTGTGCTGACTCAGCCACCCTCGGTGTCTGAAGCCCCCAGGC...</td>\n",
       "      <td>264</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                                name  \\\n",
       "0  D86993|IGLV(I)-70*01|Homo sapiens|P|V-REGION|1...   \n",
       "1  D87004|IGLV(V)-66*01|Homo sapiens|P|V-REGION|7...   \n",
       "2  X71351|IGLV(VI)-22-1*01|Homo sapiens|P|V-REGIO...   \n",
       "3  D86994|IGLV(VI)-25-1*01|Homo sapiens|P|V-REGIO...   \n",
       "4  Z73653|IGLV1-36*01|Homo sapiens|F|V-REGION|1.....   \n",
       "\n",
       "                                               value  anchor_index  \n",
       "0  CAGTCTGCGCTGACCCAGGAAGCCTCGGTGTCAGGGACCGTGGGAC...           261  \n",
       "1  CAGCCCGTGCCGACTCAGTCGACCTCTGCATCTGCCTCCCTGGGAG...           274  \n",
       "2  TGACTGCTCTGACTTAGTCTCCCTCCACCTTATGGGCACCTGGCAG...           259  \n",
       "3  CTGACTGCTCTGACTCAGTCTCCGTCTACCTCATGGACACCTGGCA...           260  \n",
       "4  CAGTCTGTGCTGACTCAGCCACCCTCGGTGTCTGAAGCCCCCAGGC...           264  "
      ]
     },
     "execution_count": 131,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "result.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 137,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "name     D87007|IGLV(I)-20*01|Homo sapiens|P|V-REGION|1...\n",
      "value    CAGTTCCTCTATTATGGTAGAGTCTGCTAGTTTCTCTGGCCCAATA...\n",
      "Name: 0, dtype: object\n",
      "name     D87009|IGLV(I)-38*01|Homo sapiens|P|V-REGION|7...\n",
      "value    CAGTCAGGGCTCACTTGGTGGCCTGCACAGTTTGTCTGTGACTAAA...\n",
      "Name: 1, dtype: object\n",
      "name     X14613|IGLV(I)-42*01|Homo sapiens|P|V-REGION|3...\n",
      "value    ATCATGGCTCATCAGGTAACCTGCACCGTCTGTCTGTGGCTAAACC...\n",
      "Name: 2, dtype: object\n",
      "name     D86996|IGLV(I)-56*01|Homo sapiens|P|V-REGION|1...\n",
      "value    TCCACATGGCACTGACAGCCTCTTTCACTGACCAAGCCTCCGGGAC...\n",
      "Name: 3, dtype: object\n",
      "name     D87022|IGLV(I)-63*01|Homo sapiens|P|V-REGION|1...\n",
      "value    CCATCTGCGCTGATTCAGTCACCCTCAGTCCCTGGGGCTCTGGGCC...\n",
      "Name: 4, dtype: object\n",
      "name     D86993|IGLV(I)-68*01|Homo sapiens|P|V-REGION|1...\n",
      "value    CAGCCTGTGCTGACCCAGCCACCTGCAGTGCATGCATCTGTGGGGC...\n",
      "Name: 5, dtype: object\n",
      "name     D86993|IGLV(I)-70*01|Homo sapiens|P|V-REGION|1...\n",
      "value    CAGTCTGCGCTGACCCAGGAAGCCTCGGTGTCAGGGACCGTGGGAC...\n",
      "Name: 6, dtype: object\n",
      "name     D86996|IGLV(IV)-53*01|Homo sapiens|P|V-REGION|...\n",
      "value    CAGGCTGGGCTGACCCAGGTGTCCTCACTCCCAGCATCTTCATGCA...\n",
      "Name: 7, dtype: object\n",
      "name     D87000|IGLV(IV)-59*01|Homo sapiens|P|V-REGION|...\n",
      "value    CTGACTCAGCTGTGTCCTCCCCCCTACTTCCTGTATCTCTGGGAGC...\n",
      "Name: 8, dtype: object\n",
      "name     D87022|IGLV(IV)-64*01|Homo sapiens|P|V-REGION|...\n",
      "value    CAGCCTGTGCTGACTCAGCCGCCCTCCCTCTCTGCACCTCCGGATC...\n",
      "Name: 9, dtype: object\n",
      "name     D87022|IGLV(IV)-65*01|Homo sapiens|P|V-REGION|...\n",
      "value    CAGCCTGTGCTGACTCAGATGACCTCACTCTCTGCATCTCCGGGAG...\n",
      "Name: 10, dtype: object\n",
      "name     D87004|IGLV(IV)-66-1*01|Homo sapiens|P|V-REGIO...\n",
      "value    CAGCCTTTGCTTATTCAGCTGCCCTCCCTCTCTGCACATCTGAGAA...\n",
      "Name: 11, dtype: object\n",
      "name     D87000|IGLV(V)-58*01|Homo sapiens|P|V-REGION|3...\n",
      "value    CAGCCTGTGCTGACTCAGTCACCCACTGCATCTGCCTCCCTGTGGG...\n",
      "Name: 12, dtype: object\n",
      "name     D87004|IGLV(V)-66*01|Homo sapiens|P|V-REGION|7...\n",
      "value    CAGCCCGTGCCGACTCAGTCGACCTCTGCATCTGCCTCCCTGGGAG...\n",
      "Name: 13, dtype: object\n",
      "name     X71351|IGLV(VI)-22-1*01|Homo sapiens|P|V-REGIO...\n",
      "value    TGACTGCTCTGACTTAGTCTCCCTCCACCTTATGGGCACCTGGCAG...\n",
      "Name: 14, dtype: object\n",
      "name     D86994|IGLV(VI)-25-1*01|Homo sapiens|P|V-REGIO...\n",
      "value    CTGACTGCTCTGACTCAGTCTCCGTCTACCTCATGGACACCTGGCA...\n",
      "Name: 15, dtype: object\n",
      "name     X99568|IGLV(VII)-41-1*01|Homo sapiens|P|V-REGI...\n",
      "value    AAGCTTGCATGCCTGCAGGTCGACTCTAGAGGATCCAGACGGAGCA...\n",
      "Name: 16, dtype: object\n",
      "name     Z73653|IGLV1-36*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGTCTGTGCTGACTCAGCCACCCTCGGTGTCTGAAGCCCCCAGGC...\n",
      "Name: 17, dtype: object\n",
      "name     M94116|IGLV1-40*01|Homo sapiens|F|V-REGION|242...\n",
      "value    CAGTCTGTGCTGACGCAGCCGCCCTCAGTGTCTGGGGCCCCAGGGC...\n",
      "Name: 18, dtype: object\n",
      "name     X53936|IGLV1-40*02|Homo sapiens|F|V-REGION|189...\n",
      "value    CAGTCTGTCGTGACGCAGCCGCCCTCAGTGTCTGGGGCCCCAGGGC...\n",
      "Name: 19, dtype: object\n",
      "name     Z22192|IGLV1-40*03|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGTCTGTCGTGACGCAGCCGCCCTCAGTGTCTGGGGCCCCAGGGC...\n",
      "Name: 20, dtype: object\n",
      "name     M94118|IGLV1-41*01|Homo sapiens|ORF|V-REGION|4...\n",
      "value    CAGTCTGTGTTGACGCAGCCGCCTTCAGTGTCTGCGGCCCCAGGAC...\n",
      "Name: 21, dtype: object\n",
      "name     D87010|IGLV1-41*02|Homo sapiens|P|V-REGION|316...\n",
      "value    CAGTCTGTGTTGACGCAGCCGCCTTCAGTGTCTGCGGCCCCAGGAC...\n",
      "Name: 22, dtype: object\n",
      "name     Z73654|IGLV1-44*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGTCTGTGCTGACTCAGCCACCCTCAGCGTCTGGGACCCCCGGGC...\n",
      "Name: 23, dtype: object\n",
      "name     Z73663|IGLV1-47*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGTCTGTGCTGACTCAGCCACCCTCAGCGTCTGGGACCCCCGGGC...\n",
      "Name: 24, dtype: object\n",
      "name     D87016|IGLV1-47*02|Homo sapiens|F|V-REGION|279...\n",
      "value    CAGTCTGTGCTGACTCAGCCACCCTCAGCGTCTGGGACCCCCGGGC...\n",
      "Name: 25, dtype: object\n",
      "name     M94112|IGLV1-50*01|Homo sapiens|ORF|V-REGION|2...\n",
      "value    CAGTCTGTGCTGACGCAGCCGCCCTCAGTGTCTGGGGCCCCAGGGC...\n",
      "Name: 26, dtype: object\n",
      "name     Z73661|IGLV1-51*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGTCTGTGTTGACGCAGCCGCCCTCAGTGTCTGCGGCCCCAGGAC...\n",
      "Name: 27, dtype: object\n",
      "name     M30446|IGLV1-51*02|Homo sapiens|F|V-REGION|55....\n",
      "value    CAGTCTGTGTTGACGCAGCCGCCCTCAGTGTCTGCGGCCCCAGGAC...\n",
      "Name: 28, dtype: object\n",
      "name     D87022|IGLV1-62*01|Homo sapiens|P|V-REGION|203...\n",
      "value    CAGTCTGTGCTGACTCAGCCACCCTCAGTGTCTTGGGCCACAAGGC...\n",
      "Name: 29, dtype: object\n",
      "name     Z73676|IGLV10-54*01|Homo sapiens|F|V-REGION|1....\n",
      "value    CAGGCAGGGCTGACTCAGCCACCCTCGGTGTCCAAGGGCTTGAGAC...\n",
      "Name: 30, dtype: object\n",
      "name     D86996|IGLV10-54*02|Homo sapiens|F|V-REGION|28...\n",
      "value    CAGGCAGGGCTGACTCAGCCACCCTCGGTGTCCAAGGGCTTGAGAC...\n",
      "Name: 31, dtype: object\n",
      "name     S70116|IGLV10-54*03|Homo sapiens|P|V-REGION|30...\n",
      "value    CAGGCAGGGCTGACTCAGCCACCCTCGGTCTCCAAGGGCTTGAGAC...\n",
      "Name: 32, dtype: object\n",
      "name     Z73651|IGLV10-67*01|Homo sapiens|P|V-REGION|1....\n",
      "value    CAGGCAGGGCAGACTCAGCAGCTCTCTGTATCCAAGGGCTTGGGAT...\n",
      "Name: 33, dtype: object\n",
      "name     X92335|IGLV10-67*02|Homo sapiens|P|V-REGION|29...\n",
      "value    CAGGCAGGGCAGACTCAGCAGCTCTCTGTATCCAAGGGCTTGGGAT...\n",
      "Name: 34, dtype: object\n",
      "name     D86996|IGLV11-55*01|Homo sapiens|ORF|V-REGION|...\n",
      "value    CGGCCCGTGCTGACTCAGCCGCCCTCTCTGTCTGCATCCCCGGGAG...\n",
      "Name: 35, dtype: object\n",
      "name     KM455555|IGLV11-55*02|Homo sapiens|ORF|V-REGIO...\n",
      "value    CGGCCCGTGCTGACTCAGCCGCCCTCCCTGTCTGCATCCCCGGGAG...\n",
      "Name: 36, dtype: object\n",
      "name     Z73657|IGLV2-11*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGTCTGCCCTGACTCAGCCTCGCTCAGTGTCCGGGTCTCCTGGAC...\n",
      "Name: 37, dtype: object\n",
      "name     Z22198|IGLV2-11*02|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGTCTGCCCTGACTCAGCCTCGCTCAGTGTCCGGGTCTCCTGGAC...\n",
      "Name: 38, dtype: object\n",
      "name     Y12415|IGLV2-11*03|Homo sapiens|F|V-REGION|1.....\n",
      "value    CTCAGTGTCCGGGTCTCCTGGACAGTCAGTCACCATCTCCTGCACT...\n",
      "Name: 39, dtype: object\n",
      "name     Z73664|IGLV2-14*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGTCTGCCCTGACTCAGCCTGCCTCCGTGTCTGGGTCTCCTGGAC...\n",
      "Name: 40, dtype: object\n",
      "name     L27822|IGLV2-14*02|Homo sapiens|F|V-REGION|175...\n",
      "value    CAGTCTGCCCTGACTCAGCCTGCCTCCGTGTCTGGGTCTCCTGGAC...\n",
      "Name: 41, dtype: object\n",
      "name     Y12412|IGLV2-14*03|Homo sapiens|F|V-REGION|1.....\n",
      "value    CTCCGTGTCTGGGTCTCCTGGACAGTCGATCACCATCTCCTGCACT...\n",
      "Name: 42, dtype: object\n",
      "name     Y12413|IGLV2-14*04|Homo sapiens|F|V-REGION|1.....\n",
      "value    CTCCGTGTCTGGGTCTCCTGGACAGTCGATCACCATCTCCTGCACT...\n",
      "Name: 43, dtype: object\n",
      "name     Z73642|IGLV2-18*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGTCTGCCCTGACTCAGCCTCCCTCCGTGTCCGGGTCTCCTGGAC...\n",
      "Name: 44, dtype: object\n",
      "name     L27697|IGLV2-18*02|Homo sapiens|F|V-REGION|88....\n",
      "value    CAGTCTGCCCTGACTCAGCCTCCCTCCGTGTCCGGGTCTCCTGGAC...\n",
      "Name: 45, dtype: object\n",
      "name     L27694|IGLV2-18*03|Homo sapiens|F|V-REGION|177...\n",
      "value    CAGTCTGCCCTGACTCAGCCTCCCTCCGTGTCCGGGTCTCCTGGAC...\n",
      "Name: 46, dtype: object\n",
      "name     L27692|IGLV2-18*04|Homo sapiens|F|V-REGION|174...\n",
      "value    CAGTCTGCCCTGACTCAGCCTCCCTCCGTGTCCGGGTCTCCTGGAC...\n",
      "Name: 47, dtype: object\n",
      "name     X14616|IGLV2-23*01|Homo sapiens|F|V-REGION|276...\n",
      "value    CAGTCTGCCCTGACTCAGCCTGCCTCCGTGTCTGGGTCTCCTGGAC...\n",
      "Name: 48, dtype: object\n",
      "name     Z73665|IGLV2-23*02|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGTCTGCCCTGACTCAGCCTGCCTCCGTGTCTGGGTCTCCTGGAC...\n",
      "Name: 49, dtype: object\n",
      "name     D86994|IGLV2-23*03|Homo sapiens|F|V-REGION|356...\n",
      "value    CAGTCTGCCCTGACTCAGCCTGCCTCCGTGTCTGGGTCTCCTGGAC...\n",
      "Name: 50, dtype: object\n",
      "name     X97466|IGLV2-28*01|Homo sapiens|P|V-REGION|1.....\n",
      "value    CAGTCTGCCCTGACTCAGCCTCACTCAGTACCCGGGTCTCCTGGAC...\n",
      "Name: 51, dtype: object\n",
      "name     Z73643|IGLV2-33*01|Homo sapiens|ORF|V-REGION|1...\n",
      "value    CAATCTGCCCTGACTCAGCCTCCTTTTGTGTCCGGGGCTCCTGGAC...\n",
      "Name: 52, dtype: object\n",
      "name     L27823|IGLV2-33*02|Homo sapiens|ORF|V-REGION|1...\n",
      "value    CAGTCTGCCCTGACTCAGCCTCCTTTTGTGTCCGGGGCTCCTGGAC...\n",
      "Name: 53, dtype: object\n",
      "name     L27691|IGLV2-33*03|Homo sapiens|ORF|V-REGION|1...\n",
      "value    CAATCTGCCCTGACTCAGCCTCCTTTTGTGTCCGGGGCTCCTGGAC...\n",
      "Name: 54, dtype: object\n",
      "name     D87013|IGLV2-34*01|Homo sapiens|P|V-REGION|303...\n",
      "value    CAGTCTGTTCTGACTCAGCCTCGCTCAGTGTCCAGGTCTCCTGGAC...\n",
      "Name: 55, dtype: object\n",
      "name     Z22209|IGLV2-34*02|Homo sapiens|P|V-REGION|1.....\n",
      "value    CAGTCTGTTCTGACTCAGCCTCGCTCAGTGTCCAGGTCTCCTGGAC...\n",
      "Name: 56, dtype: object\n",
      "name     Z73641|IGLV2-5*01|Homo sapiens|P|V-REGION|1..2...\n",
      "value    CAGTCTGCCCTGATTCAGCCTCCCTCCGTGTCCGGGTCTCCTGGAC...\n",
      "Name: 57, dtype: object\n",
      "name     X57825|IGLV2-5*02|Homo sapiens|P|V-REGION|359....\n",
      "value    CAGTCTGCCCTGATTCAGCCTCCCTCCGTGTCCGGGTCTCCTGGAC...\n",
      "Name: 58, dtype: object\n",
      "name     X97462|IGLV2-8*01|Homo sapiens|F|V-REGION|1..2...\n",
      "value    CAGTCTGCCCTGACTCAGCCTCCCTCCGCGTCCGGGTCTCCTGGAC...\n",
      "Name: 59, dtype: object\n",
      "name     L27695|IGLV2-8*02|Homo sapiens|F|V-REGION|173....\n",
      "value    CAGTCTGCCCTGACTCAGCCTCCCTCCGCGTCCAGGTCTCCTGGAC...\n",
      "Name: 60, dtype: object\n",
      "name     Y12418|IGLV2-8*03|Homo sapiens|F|V-REGION|1..2...\n",
      "value    CTCCGCGTCCGGGTCTCCTGGACAGTCAGTCACCATCTCCTGCACT...\n",
      "Name: 61, dtype: object\n",
      "name     X57826|IGLV3-1*01|Homo sapiens|F|V-REGION|2256...\n",
      "value    TCCTATGAGCTGACTCAGCCACCCTCAGTGTCCGTGTCCCCAGGAC...\n",
      "Name: 62, dtype: object\n",
      "name     X97464|IGLV3-10*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    TCCTATGAGCTGACACAGCCACCCTCGGTGTCAGTGTCCCCAGGAC...\n",
      "Name: 63, dtype: object\n",
      "name     L29166|IGLV3-10*02|Homo sapiens|F|V-REGION|241...\n",
      "value    TCCTATGAGCTGACACAGCCACCCTCGGTGTCAGTGTCCCCAGGAC...\n",
      "Name: 64, dtype: object\n",
      "name     Z73658|IGLV3-12*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    TCCTATGAGCTGACTCAGCCACACTCAGTGTCAGTGGCCACAGCAC...\n",
      "Name: 65, dtype: object\n",
      "name     D86998|IGLV3-12*02|Homo sapiens|F|V-REGION|101...\n",
      "value    TCCTATGAGCTGACTCAGCCACACTCAGTGTCAGTGGCCACAGCAC...\n",
      "Name: 66, dtype: object\n",
      "name     X97463|IGLV3-13*01|Homo sapiens|P|V-REGION|1.....\n",
      "value    TCCTATGAGCTGACACAGCCACCCGCGGTGTCAGTGTCCCCAGGAC...\n",
      "Name: 67, dtype: object\n",
      "name     D87015|IGLV3-15*01|Homo sapiens|P|V-REGION|254...\n",
      "value    ACCTATGAGCTGACACAGTCACCCTCAGCGTCAGTGGCCCCAGGAC...\n",
      "Name: 68, dtype: object\n",
      "name     X97471|IGLV3-16*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    TCCTATGAGCTGACACAGCCACCCTCGGTGTCAGTGTCCCTAGGAC...\n",
      "Name: 69, dtype: object\n",
      "name     X97472|IGLV3-17*01|Homo sapiens|P|V-REGION|1.....\n",
      "value    TCCCGTAAGCTGACTCCAGAGCCAGCAGTGTCTGTGGACAGTCAGC...\n",
      "Name: 70, dtype: object\n",
      "name     X56178|IGLV3-19*01|Homo sapiens|F|V-REGION|201...\n",
      "value    TCTTCTGAGCTGACTCAGGACCCTGCTGTGTCTGTGGCCTTGGGAC...\n",
      "Name: 71, dtype: object\n",
      "name     X97468|IGLV3-2*01|Homo sapiens|P|V-REGION|1..2...\n",
      "value    TCCTCTGAGCTGACTCAGCTGCCTGCAGTGTCTGTGGCTTTGGGAC...\n",
      "Name: 72, dtype: object\n",
      "name     X57828|IGLV3-2*02|Homo sapiens|P|V-REGION|1837...\n",
      "value    TCCTCTGAGCTGACTCAGCTGCCTGCAGTGTCTGTGGCTTTGGGAC...\n",
      "Name: 73, dtype: object\n",
      "name     X71966|IGLV3-21*01|Homo sapiens|F|V-REGION|688...\n",
      "value    TCCTATGTGCTGACTCAGCCACCCTCAGTGTCAGTGGCCCCAGGAA...\n",
      "Name: 74, dtype: object\n",
      "name     D87007|IGLV3-21*02|Homo sapiens|F|V-REGION|133...\n",
      "value    TCCTATGTGCTGACTCAGCCACCCTCGGTGTCAGTGGCCCCAGGAC...\n",
      "Name: 75, dtype: object\n",
      "name     M94115|IGLV3-21*03|Homo sapiens|F|V-REGION|637...\n",
      "value    TCCTATGTGCTGACTCAGCCACCCTCGGTGTCAGTGGCCCCAGGAA...\n",
      "Name: 76, dtype: object\n",
      "name     Z73666|IGLV3-22*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    TCCTATGAGCTGACACAGCTACCCTCGGTGTCAGTGTCCCCAGGAC...\n",
      "Name: 77, dtype: object\n",
      "name     X71967|IGLV3-22*02|Homo sapiens|P|V-REGION|256...\n",
      "value    TCCTATGAGCTGACACAGCTACCCTCGGTGTCAGTGTCCCCAGGAC...\n",
      "Name: 78, dtype: object\n",
      "name     X71968|IGLV3-24*01|Homo sapiens|P|V-REGION|347...\n",
      "value    TCCTATGAGCTGACACAGCCACCCTCAGTGTCAGTAGCTCCAGGAC...\n",
      "Name: 79, dtype: object\n",
      "name     D86994|IGLV3-24*02|Homo sapiens|P|V-REGION|322...\n",
      "value    TCCTGTGAGCTGACACAGCCACCCTCAGTGTCAGTAGCTCCAGGAC...\n",
      "Name: 80, dtype: object\n",
      "name     X97474|IGLV3-25*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    TCCTATGAGCTGATGCAGCCACCCTCGGTGTCAGTGTCCCCAGGAC...\n",
      "Name: 81, dtype: object\n",
      "name     D86994|IGLV3-25*02|Homo sapiens|F|V-REGION|244...\n",
      "value    TCCTATGAGCTGACACAGCCACCCTCGGTGTCAGTGTCCCCAGGAC...\n",
      "Name: 82, dtype: object\n",
      "name     L29165|IGLV3-25*03|Homo sapiens|F|V-REGION|252...\n",
      "value    TCCTATGAGCTGACACAGCCACCCTCGGTGTCAGTGTCCCCAGGAC...\n",
      "Name: 83, dtype: object\n",
      "name     X97467|IGLV3-26*01|Homo sapiens|P|V-REGION|1.....\n",
      "value    TCCTCCATGCTGACTCAGGAGCCAGTAGGGTCTGTGGCCCTGGGAC...\n",
      "Name: 84, dtype: object\n",
      "name     D86994|IGLV3-27*01|Homo sapiens|F|V-REGION|598...\n",
      "value    TCCTATGAGCTGACACAGCCATCCTCAGTGTCAGTGTCTCCGGGAC...\n",
      "Name: 85, dtype: object\n",
      "name     Z73644|IGLV3-29*01|Homo sapiens|P|V-REGION|1.....\n",
      "value    TCATATGTGCTGACACAGCCACCCTCAGTGTCAGTGGCCCCAGGAC...\n",
      "Name: 86, dtype: object\n",
      "name     Z73646|IGLV3-30*01|Homo sapiens|P|V-REGION|1.....\n",
      "value    ACATATGAGCTGTCTCAGCCACCCTCAGTGTCAGTGGCCCCATTAC...\n",
      "Name: 87, dtype: object\n",
      "name     D87014|IGLV3-30*02|Homo sapiens|P|V-REGION|363...\n",
      "value    ACATATGAGCTGTCTCAGCCACCCTCAGTGTCAGTGGCCCCATTAC...\n",
      "Name: 88, dtype: object\n",
      "name     X97469|IGLV3-31*01|Homo sapiens|P|V-REGION|1.....\n",
      "value    TCCTCTGAGCTGAGTCAGGAGCCTGCAGTGTCTGTGGCCTTGGGAT...\n",
      "Name: 89, dtype: object\n",
      "name     Z22203|IGLV3-31*02|Homo sapiens|P|V-REGION|1.....\n",
      "value    TCCTCTGAGCTGAGTCAGGAGCCTGCAGTGTCTGTGTCCTTGGGAT...\n",
      "Name: 90, dtype: object\n",
      "name     Z73645|IGLV3-32*01|Homo sapiens|ORF|V-REGION|1...\n",
      "value    TCCTCTGGGCCAACTCAGGTGCCTGCAGTGTCTGTGGCCTTGGGAC...\n",
      "Name: 91, dtype: object\n",
      "name     D87024|IGLV3-4*01|Homo sapiens|P|V-REGION|2528...\n",
      "value    TTCTCTAAGCTGACTCAGCTGCCTGAAGTGTCTGTGGCTTTGGGAC...\n",
      "Name: 92, dtype: object\n",
      "name     X97465|IGLV3-6*01|Homo sapiens|P|V-REGION|1..2...\n",
      "value    TCCTATGAGCTTACACAGCCACCCTCAGTGTCAGTGTCACCAGGAC...\n",
      "Name: 93, dtype: object\n",
      "name     X57827|IGLV3-6*02|Homo sapiens|P|V-REGION|683....\n",
      "value    CTCCTATGAGCTTACACAGCCACCCTCAGTGTCAGTGTCACCAGGA...\n",
      "Name: 94, dtype: object\n",
      "name     X97470|IGLV3-7*01|Homo sapiens|P|V-REGION|1..2...\n",
      "value    TCCTCTGAGCGGACTCAGTTGCCTGCAGCGTCTGTGGCTTTGGGAC...\n",
      "Name: 95, dtype: object\n",
      "name     X97473|IGLV3-9*01|Homo sapiens|F|V-REGION|1..2...\n",
      "value    TCCTATGAGCTGACTCAGCCACTCTCAGTGTCAGTGGCCCTGGGAC...\n",
      "Name: 96, dtype: object\n",
      "name     X74288|IGLV3-9*02|Homo sapiens|F|V-REGION|354....\n",
      "value    TCCTATGAGCTGACTCAGCCACTCTCAGTGTCAGTGGCCCTGGGAC...\n",
      "Name: 97, dtype: object\n",
      "name     X51754|IGLV3-9*03|Homo sapiens|P|V-REGION|1914...\n",
      "value    TCCTATGAGCTGACTCAGCCACTCTCAGTGTCAGTGGCCCTGGGAC...\n",
      "Name: 98, dtype: object\n",
      "name     X57828|IGLV4-3*01|Homo sapiens|F|V-REGION|356....\n",
      "value    CTGCCTGTGCTGACTCAGCCCCCGTCTGCATCTGCCTTGCTGGGAG...\n",
      "Name: 99, dtype: object\n",
      "name     Z73667|IGLV4-60*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGCCTGTGCTGACTCAATCATCCTCTGCCTCTGCTTCCCTGGGAT...\n",
      "Name: 100, dtype: object\n",
      "name     D87000|IGLV4-60*02|Homo sapiens|F|V-REGION|129...\n",
      "value    CAGCCTGTGCTGACTCAATCATCCTCTGCCTCTGCTTCCCTGGGAT...\n",
      "Name: 101, dtype: object\n",
      "name     AF073885|IGLV4-60*03|Homo sapiens|F|V-REGION|1...\n",
      "value    CAGCCTGTGCTGACTCAATCATCCTCTGCCTCTGCTTCCCTGGGAT...\n",
      "Name: 102, dtype: object\n",
      "name     Z73648|IGLV4-69*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGCTTGTGCTGACTCAATCGCCCTCTGCCTCTGCCTCCCTGGGAG...\n",
      "Name: 103, dtype: object\n",
      "name     U03868|IGLV4-69*02|Homo sapiens|F|V-REGION|161...\n",
      "value    CAGCTTGTGCTGACTCAATCGCCCTCTGCCTCTGCCTCCCTGGGAG...\n",
      "Name: 104, dtype: object\n",
      "name     Z73672|IGLV5-37*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGCCTGTGCTGACTCAGCCACCTTCCTCCTCCGCATCTCCTGGAG...\n",
      "Name: 105, dtype: object\n",
      "name     Z73668|IGLV5-39*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGCCTGTGCTGACTCAGCCAACCTCCCTCTCAGCATCTCCTGGAG...\n",
      "Name: 106, dtype: object\n",
      "name     AF216776|IGLV5-39*02|Homo sapiens|F|V-REGION|1...\n",
      "value    CAGCCTGTGCTGACTCAGCCAACCTCCCTCTCAGCATCTCCTGGAG...\n",
      "Name: 107, dtype: object\n",
      "name     Z73670|IGLV5-45*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGGCTGTGCTGACTCAGCCGGCTTCCCTCTCTGCATCTCCTGGAG...\n",
      "Name: 108, dtype: object\n",
      "name     Z73671|IGLV5-45*02|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGGCTGTGCTGACTCAGCCGTCTTCCCTCTCTGCATCTCCTGGAG...\n",
      "Name: 109, dtype: object\n",
      "name     D86999|IGLV5-45*03|Homo sapiens|F|V-REGION|157...\n",
      "value    CAGGCTGTGCTGACTCAGCCGTCTTCCCTCTCTGCATCTCCTGGAG...\n",
      "Name: 110, dtype: object\n",
      "name     KM455553|IGLV5-45*04|Homo sapiens|F|V-REGION|1...\n",
      "value    CAGGCTGTGCTGACTCAGCCGTCTTCCCTCTCTGCATCTCCTGGAG...\n",
      "Name: 111, dtype: object\n",
      "name     Z73649|IGLV5-48*01|Homo sapiens|ORF|V-REGION|1...\n",
      "value    CAGCCTGTGCTGACTCAGCCAACTTCCCTCTCAGCATCTCCTGGAG...\n",
      "Name: 112, dtype: object\n",
      "name     KM455554|IGLV5-48*02|Homo sapiens|P|V-REGION|1...\n",
      "value    CAGGCTGTGCTGACTCAGCCAACTTCCCTCTCAGCATCTCCTGGAG...\n",
      "Name: 113, dtype: object\n",
      "name     Z73669|IGLV5-52*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGCCTGTGCTGACTCAGCCATCTTCCCATTCTGCATCTTCTGGAG...\n",
      "Name: 114, dtype: object\n",
      "name     Z73673|IGLV6-57*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    AATTTTATGCTGACTCAGCCCCACTCTGTGTCGGAGTCTCCGGGGA...\n",
      "Name: 115, dtype: object\n",
      "name     KM455556|IGLV6-57*02|Homo sapiens|F|V-REGION|1...\n",
      "value    AATTTTATGCTGACTCAGCCCCACTCTGTGTCGGAGTCTCCGGGGA...\n",
      "Name: 116, dtype: object\n",
      "name     Z73660|IGLV7-35*01|Homo sapiens|P|V-REGION|1.....\n",
      "value    CAGGCTGTGATGACTCAGGAACCCTCACTGACTGTGTCCCCAGGAG...\n",
      "Name: 117, dtype: object\n",
      "name     X14614|IGLV7-43*01|Homo sapiens|F|V-REGION|414...\n",
      "value    CAGACTGTGGTGACTCAGGAGCCCTCACTGACTGTGTCCCCAGGAG...\n",
      "Name: 118, dtype: object\n",
      "name     Z73674|IGLV7-46*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGGCTGTGGTGACTCAGGAGCCCTCACTGACTGTGTCCCCAGGAG...\n",
      "Name: 119, dtype: object\n",
      "name     D86999|IGLV7-46*02|Homo sapiens|F|V-REGION|929...\n",
      "value    CAGGCTGTGGTGACTCAGGAGCCCTCACTGACTGTGTCCCCAGGAG...\n",
      "Name: 120, dtype: object\n",
      "name     Z22210|IGLV7-46*03|Homo sapiens|P|V-REGION|1.....\n",
      "value    CAGGCTGTGGTGACTCAGGAGCCCTCACTGACTGTGTCCCCAGGAG...\n",
      "Name: 121, dtype: object\n",
      "name     Z73650|IGLV8-61*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGACTGTGGTGACCCAGGAGCCATCGTTCTCAGTGTCCCCTGGAG...\n",
      "Name: 122, dtype: object\n",
      "name     U03637|IGLV8-61*02|Homo sapiens|F|V-REGION|454...\n",
      "value    CAGACTGTGGTGACCCAGGAGCCATCGTTCTCAGTGTCCCCTGGAG...\n",
      "Name: 123, dtype: object\n",
      "name     AF266511|IGLV8-61*03|Homo sapiens|F|V-REGION|1...\n",
      "value    GGTGACCCAGGAGCCATCGTTCTCAGTGTCCCCTGGAGGGACAGTC...\n",
      "Name: 124, dtype: object\n",
      "name     Y08831|IGLV8/OR8-1*01|Homo sapiens|P|V-REGION|...\n",
      "value    CAGTCTGTGGTGACCCAGGAGCCATCACTCTCAGGGTCTCCTGGAG...\n",
      "Name: 125, dtype: object\n",
      "name     U03636|IGLV8/OR8-1*02|Homo sapiens|ORF|V-REGIO...\n",
      "value    CAGTCTGTGGTGACCCAGGAGCCATCACTCTCAGGGTCTCCTGGAG...\n",
      "Name: 126, dtype: object\n",
      "name     Z73675|IGLV9-49*01|Homo sapiens|F|V-REGION|1.....\n",
      "value    CAGCCTGTGCTGACTCAGCCACCTTCTGCATCAGCCTCCCTGGGAG...\n",
      "Name: 127, dtype: object\n",
      "name     D87016|IGLV9-49*02|Homo sapiens|F|V-REGION|134...\n",
      "value    CAGCCTGTGCTGACTCAGCCACCTTCTGCATCAGCCTCCCTGGGAG...\n",
      "Name: 128, dtype: object\n",
      "name     U03869|IGLV9-49*03|Homo sapiens|F|V-REGION|206...\n",
      "value    CAGCCTGTGCTGACTCAGCCACCTTCTGCATCAGCCTCCCTGGGAG...\n",
      "Name: 129, dtype: object\n"
     ]
    }
   ],
   "source": [
    "for index, row in ev_da.iterrows():\n",
    "    print(row)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 125,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "mdl.xdata['v_choice']"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "mdl.xdata['v_choice'][{'v_choice':[0,1]}]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "mdl_parms.Event_dict\n",
    "evento = mdl_parms.get_Event('v_choice') #get_realization_DataFrame()\n",
    "#print(evento)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "mdl.parms.get_Event('v_choice')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "mdl_anchs.df_Vanchors.loc[0]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "ev_da = evento.get_realization_DataFrame()\n",
    "ev_da.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "ev_da_drop = ev_da.drop([0,2,4]) #.head()\n",
    "aaa = ev_da_drop.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "aaa"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "bbb=aaa.reset_index(drop=True)\n",
    "bbb"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "mdl = p3.IgorModel(model_parms_file=fln_model_parms, model_parms_file=fln_model_parms)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 122,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "Int64Index([  0,   1,   2,   3,   4,   5,   6,   7,   8,   9,\n",
       "            ...\n",
       "             94,  95,  96,  97,  98,  99, 100, 101, 102, 103],\n",
       "           dtype='int64', length=104)"
      ]
     },
     "execution_count": 122,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "new_df.index"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 119,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>value</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>D86993|IGLV(I)-70*01|Homo sapiens|P|V-REGION|1...</td>\n",
       "      <td>CAGTCTGCGCTGACCCAGGAAGCCTCGGTGTCAGGGACCGTGGGAC...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>D87004|IGLV(V)-66*01|Homo sapiens|P|V-REGION|7...</td>\n",
       "      <td>CAGCCCGTGCCGACTCAGTCGACCTCTGCATCTGCCTCCCTGGGAG...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>X71351|IGLV(VI)-22-1*01|Homo sapiens|P|V-REGIO...</td>\n",
       "      <td>TGACTGCTCTGACTTAGTCTCCCTCCACCTTATGGGCACCTGGCAG...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>D86994|IGLV(VI)-25-1*01|Homo sapiens|P|V-REGIO...</td>\n",
       "      <td>CTGACTGCTCTGACTCAGTCTCCGTCTACCTCATGGACACCTGGCA...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>Z73653|IGLV1-36*01|Homo sapiens|F|V-REGION|1.....</td>\n",
       "      <td>CAGTCTGTGCTGACTCAGCCACCCTCGGTGTCTGAAGCCCCCAGGC...</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                                name  \\\n",
       "0  D86993|IGLV(I)-70*01|Homo sapiens|P|V-REGION|1...   \n",
       "1  D87004|IGLV(V)-66*01|Homo sapiens|P|V-REGION|7...   \n",
       "2  X71351|IGLV(VI)-22-1*01|Homo sapiens|P|V-REGIO...   \n",
       "3  D86994|IGLV(VI)-25-1*01|Homo sapiens|P|V-REGIO...   \n",
       "4  Z73653|IGLV1-36*01|Homo sapiens|F|V-REGION|1.....   \n",
       "\n",
       "                                               value  \n",
       "0  CAGTCTGCGCTGACCCAGGAAGCCTCGGTGTCAGGGACCGTGGGAC...  \n",
       "1  CAGCCCGTGCCGACTCAGTCGACCTCTGCATCTGCCTCCCTGGGAG...  \n",
       "2  TGACTGCTCTGACTTAGTCTCCCTCCACCTTATGGGCACCTGGCAG...  \n",
       "3  CTGACTGCTCTGACTCAGTCTCCGTCTACCTCATGGACACCTGGCA...  \n",
       "4  CAGTCTGTGCTGACTCAGCCACCCTCGGTGTCTGAAGCCCCCAGGC...  "
      ]
     },
     "execution_count": 119,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import pandas as pd\n",
    "df_Vanchors = mdl_anchs.df_Vanchors.rename(columns={'gene': 'name'})\n",
    "result = pd.merge(ev_da, df_Vanchors, on='name')  # , left_index=True, right_index=True, how='inner');\n",
    "new_df = result.drop(columns=['anchor_index'])\n",
    "# set dataframe to envento\n",
    "\n",
    "new_df.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "new_df.loc[1]#.to_dict()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "for index, row in new_df.iterrows():\n",
    "    dicto = row.to_dict()\n",
    "    dicto['index'] = index\n",
    "    print(dicto)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.7.6"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 4
}
