title: Nested dictionary comprehension combined with using values as key:value
body: <p>I have a data structure in the following format:</p>
  
  <pre><code>dict = {
          garbage1:{currency: 'JPY', maturity: 20apr2021, yield:-0.50%}, 
          garbage2:{currency: 'JPY', maturity: 30mar2022, yield:-0.2%},
          garbage3:{currency: 'EUR', maturity: 15may2021, yield: +0.1%}
         }
  </code></pre>
  
  <p>I would like this to become</p>
  
  <pre><code>new_dict = {
              'JPY': {20apr2021:-0.50%, 30mar2022,-0.20%},
              'EUR': {15may2021:+0.1%}
             }
  </code></pre>
  
  <p>So i'm trying to use nested dictionary comprehension and combine that with turning the values into a key value. Struggling. This is the furthest I can get thus far:</p>
  
  <pre><code>new_dict = {outer_val: {inner_val["maturity"]: inner_val["yield"] for inner_key, inner_val in outer_val.items()}
              for outer_key, outer_val in dict.items()}
  </code></pre>