Behavioural task and training

All experiments were performed on female Long Evans rats ~14-weeks-old (~250 g; Harlan Laboratories). Rats were trained in a chamber with three reward ports that were situated 90° apart (Fig. 1a). Each port was fit with a visible broad-spectrum LED, and an infrared LED (Opto Semiconductors Inc., 940 nm peak emittance (range of non-zero emissions was between 825 and 1000, nm), and IR intensity dropped to half-max at 120°) (Fig. 1a). We first trained water-deprived rats to poke in the port whose visible LED was activated. Each trial began when a visible light in one randomly selected port was activated. Rats received water when they broke the photobeam in that port (correct trials). Trials counted as incorrect when the rats poked in a different port, or did not poke at all and let the trial terminate (this was set to occur between 15 and 20 seconds after the onset of the light). On incorrect trials, they received no water, an error tone, and a longer delay to the next trial. For some rats, we delivered air puffs to the face on incorrect trials.

Once animals performed above a criterion value (>70% correct) >4 days in a row, we implanted an array of stimulating electrodes into S1 (Fig. 1d). The array includes an IR detector attached to the connector (see Fig. 1c and Surgery below). After the animals recovered from surgery, we determined the minimal currents required to evoke a behavioural response in at least two electrode pairs (thresholds were between 1 and 200 μA, see Stimulating Electrodes and Stimulator below for details). We then trained them in the same behavioural chamber, but incrementally replacing visible light with ICMS linked to IR levels from their detector (Fig. 1e).

Initially, each trial had the same structure as trials in the initial behavioral task described above, except that the onset of the visible light was preceded by IR-level dependent stimulation (up to 400 Hz) that lasted 0.6–1.5 s. In four of six rats, we began with brief durations of stimulation (600–700 ms) to acclimate them to stimulation. In two of the rats, we started with longer stimulation durations to get estimates of behavioural latency as they learned the task (Fig. 2b). Thus the animals learned that stimulation indicated the presence of the visible light. The stimulation frequency was exponentially proportional to the IR levels (Fig. 1e). We used an exponential function because IR intensity dropped logarithmically from the IR source. We stimulated at high frequencies for two reasons: one, in preliminary experiments we found that using a lower frequency range (that is, 0–100 Hz) yielded less reliable performance; two, we wished to avoid evoking kindling seizures34. Stimulation frequencies were updated every 50 ms based on IR levels, and it took ~5 ms for the stimulation frequency to actually change in the rat once the command was sent. Pulse frequency was the only variable that tracked IR levels: current amplitudes were kept the same for each pulse.

Once it became clear, based on visual inspection, that the animals were comfortable with stimulation, we added ‘IR-only’ trials in which the IR-dependent stimulation would appear without any accompanying visible light. That is, on these IR-only trials they could only use the signals from ICMS to get to the correct port. They trained on this until their performance on the IR-only trials reached a criterion value of 70% correct. For some rats that stayed above criterion for four sessions in a row, we then varied task difficulty in which across sessions, we pseudo-randomly chose a new angle between the ports (either 90, 60, 45 or 30 degrees; Fig. 2c).

On some sessions, we added a small percentage of trials (~15%) in which the stimulation frequency was held constant, regardless of the IR intensity. Such constant-frequency trials allowed us to compare performance when the stimulation frequency depended on IR levels with those trials when stimulation frequency was a constant function of IR intensity (Fig. 2d, left hand side).

All behaviour control was run in custom Matlab scripts using the data acquisition toolbox (run with NIDAQ PCI-7742 card, National Instruments).

Stimulating electrodes and stimulator

In preliminary studies, we found that the thresholds for evoking behavioural responses were lower with electrode pairs within the same penetration of the cortex. Hence, for each biphasic stimulating electrode, we joined pairs of 30-μm stainless steel microwires to one another, each pair separated by 300 μm (Fig. 1c inset). We attached a single infrared detector (Lite-On Inc) to the connector (Omnetics), and powered the IR detector through the two extra reference pins on the connector. The phototransistor in the detector had a peak spectral sensitivity at a wavelength of 940 nm. The range of sensitivity was from 860 to 1020, nm, and its ‘receptive field’ (that is, the angular range within which a 940 nm test stimuli would evoke a response from the detector) was 20° in diameter at half-max (Fig. 1a).

We used bipolar stimulation with charge-balanced, biphasic pulse trains, using a custom-controlled stimulator, as described elsewhere35. Pulses were 100 μs in duration, with 50 μs between the cathodic and anodic phases of the pulses (Fig. 1e). Current magnitudes varied between 1 and 300 μA. Before training rats on the IR-version of the task, we determined current thresholds by placing them in the empty behavioural chamber (Fig. 1a), and stimulating with 1 μA at 200 Hz for 500 ms. If an animal noticeably moved in response to stimulation (this typically involved locomoting, moving their heads to the side or scratching at their faces), that current level was taken as the threshold current. If not, we increased the current amplitude by 50%, keeping the frequency and duration the same, until we noted such a response. We used electrical microstimulation in lieu of optogenetics in this study, as one goal is to integrate this technology into human studies in the near future (see Discussion).

Surgery

Detailed surgical procedures are described elsewhere36. Briefly, we implanted the stimulating electrodes into S1 (−2.5 mm posterior and 5.5 mm relative to bregma, 1.5 mm deep) under pentobarbital anaesthesia (0.065 mg g−1), and the rats were given at least a week to recover from the surgery before being deprived again. The Duke University Institutional Animal Use Committee approved all surgical and behavioural methods.

Neural recording and sorting

The basic recording set-up is described in detail elsewhere36. Namely, on those channels that we were not using for stimulation, we recorded neural activity using the (Multichannel Acquisition Processor (Plexon, Inc., Dallas, Texas)). To stimulate and record simultaneously without damaging the head stage, we peeled off the wires connected to the stimulator from the connector to bypass the head stage, while the other channels went directly to the head stage. Sorting of neural data is also described elsewhere36. Briefly, in addition to template-based online sorting, all voltage traces around a threshold-crossing event were saved for offline sorting. For offline sorting, we used clustering in principal component space, signal to noise ratio and autocorrelation functions that showed a clear absolute and relative refractory period to determine whether the data came from single units or multiple units.

In our recordings, we lightly anesthetized head-fixed animals under isofluorane anaesthesia (0.8–3% isofluorane mixed with pure oxygen). We controlled the duration and magnitude (psi) of air via a modified fluid dispenser (Oki DX-250, Garden Grove, CA), which was controlled with TTL pulses sent from Matlab. Before recording, we positioned the air dispenser to stimulate the majority of the large whiskers, ~10 mm from the whisker pad. We delivered three different stimuli, in pseudo-random order: air puff to whiskers, electrical stimulation and both stimuli delivered simultaneously (see Fig. 3).

Statistical methods

We calculated significant responses in peristimulus time histograms using a bootstrap cumulative sum algorithm described in more detail elsewhere37. This involved taking bootstrap samples of the cumulative response during a baseline period (period before time zero in Fig. 3a), and using these to generate a cumulative sum 95% confidence interval (with Bonferonni correction for multiple comparisons), and comparing this to the actual cumulative sum during the period of stimulation. A significant response was when the actual cumulative sum left the 95% confidence interval, and ended when the response dropped below a 95% confidence interval estimated from bootstrapping the original data.

During electrical stimulation, recordings were saturated by stimulus artifact, so to directly compare responses between whisker deflection and ICMS, we compared mean firing rates during the 130 ms period following the offset of both stimuli. To compare relative response magnitudes among multiple neurons, we normalized the mean response to each stimulus by the maximum mean response over all three stimulus conditions, so the maximum response was assigned a value of one.

To generate the predicted responses to both stimuli delivered simultaneously (Fig. 3c), we used the normalized responses described in the previous paragraph. For a linear system, the predicted response to both stimuli would simply be the sum of the responses to each stimulus taken individually. That is, R(E+W)=R(E)+R(W), where E is electrical stimulation, W is whisker deflection, and R(x) signifies the response to input x.