title: Django: Model Queryset to Pandas to Django Rest Framework
body: <p>I am trying to accomplish the following workflow in my Django project:</p>
  
  <ol>
  <li>Query my database </li>
  <li>Convert the returned queryset to a pandas dataframe in order to perform some calculations &amp; filtering  </li>
  <li>Pass the final dataframe to Django REST API Framework</li>
  </ol>
  
  <p>if I understand correctly, I have to use django-pandas for Step 2. and Django REST Pandas for Step 3. 
  I installed both and read the documentaton, but I have no clue how to make it work. </p>
  
  <p>What I have achieved to far is to set up my model, views, serializes and urls to have the original queryset rendered via the Django Rest Framework.</p>
  
  <p>If anyone could give me a hint on how to integrate pandas in this workflow, it would be highly appreciated.</p>
  
  <p>my models.py file</p>
  
  <pre><code>from django.db import models
  
  class Fund(models.Model):
      name = models.CharField(max_length=100)
      commitment_size = models.IntegerField(blank=True, null=True)
      commitment_date = models.DateField(blank=True, null=True)
  
      def __str__(self):
          return self.name
  </code></pre>
  
  <p>my views.py file</p>
  
  <pre><code>from rest_framework import generics
  from rest_framework.views import APIView
  
  from pages.models import Fund
  from .serializers import FundSerializer
  
  class FundAPIView(generics.ListAPIView):
      queryset = Fund.objects.all()
      serializer_class = FundSerializer
  </code></pre>
  
  <p>my serializers.oy file</p>
  
  <pre><code>from rest_framework import serializers
  
  from pages.models import Fund
  
  class FundSerializer(serializers.ModelSerializer):
      class Meta:
          model = Fund
          fields = ('name', 'commitment_size', 'commitment_date')
  </code></pre>