Foreign portfolio investors invested Rs 6,480 crore in Indian markets in October, reversing months of outflows.